When “Limit workflow to specific users” is enabled and at least one
administrator is selected, unauthenticated access to the admin area fails
with a 500 error.
This prevents the admin login page from loading after logout or after the
administrative session expires.
Steps to reproduce:
- Sign in to the TastyIgniter admin panel.
- Open the Order settings.
- Enable the order status workflow.
- Enable “Limit workflow to specific users”.
- Select at least one administrator and save the settings.
- Log out, expire the session, or access the admin login URL without an
authenticated session.
Expected behavior
The login page should load normally.
The order status workflow modal should only be injected when an administrator
is authenticated.
#Actual behavior:
The request returns HTTP 500:
Call to a member function getKey() on null
Igniter\Cart\Http\Middleware\InjectStatusWorkflow.php