openfoodnetwork icon indicating copy to clipboard operation
openfoodnetwork copied to clipboard

Error 401 when populating the cart - checking out after a user admin-disabled user attempts log in

Open filipefurtad0 opened this issue 2 years ago • 0 comments

Description

It is not possible to populate the cart after attempting to log in with a user disabled by the admin, within the same browser/session. This triggers a 401 error.

Expected Behavior

Despite a previous attempt to log in with a admin-disabled user, logging in with non-disabled account should allow cart populate and checkout.

Actual Behaviour

After a an attempt to log in with a admin-disabled user, logging in with non-disabled account does not allow cart populate and checkout.

Steps to Reproduce

  1. Try to login with an admin-disabled account
  2. See the error message Your account has been disabled. Please contact an administrator to solve this issue.
  3. Log in with a non-disabled account
  4. Add some items to the cart
  5. Open the console
  6. Open the cart side menu and notice it keeps "updating cart"
  7. Notice the 401 error
  8. Click "Checkout" anyway and accept/confirm the "moving away from the page" modal
  9. See the error No valid order found for checkout processing

Animated Gif/Screenshot

image

image

Workaround

Start a fresh session on the browser.

Severity

Edge case? -> s4; checkout blocker? -> s2 I'd go for s3. I'm wondering if customer support has heard of this one yet. If so, we could upgrade the severity.

Your Environment

  • Version used: v4.2.9
  • Browser name and version: Firefox 102
  • Operating System and version (desktop or mobile): Ubuntu 22.04

Possible Fix

filipefurtad0 avatar Aug 12 '22 12:08 filipefurtad0