- Issue created by @andyg5000
- Status changed to Needs review
8 months ago 10:16pm 9 November 2023 - last update
8 months ago Patch Failed to Apply - πΊπΈUnited States andyg5000 North Carolina, USA
Here's a patch that's fixing the issue for me.
- last update
8 months ago 23 pass - πΊπΈUnited States loze
Im getting the following error when adding a product to the cart with ajax, both with and without this patch.
If i disable the module it goes away.
I'm using Drupal 9.5.11
"
An AJAX HTTP error occurred.
HTTP Result Code: 200
Debugging information follows.
Path: /event/365052?ajax_form=1
StatusText: OK
ResponseText: TypeError: Drupal\commerce\Context::__construct(): Argument #1 ($customer) must be of type Drupal\Core\Session\AccountInterface, null given, called in /Users/XXXXX/web/modules/contrib/commerce/modules/cart/src/Form/AddToCartForm.php on line 248 in Drupal\commerce\Context->__construct() (line 58 of /Users/XXXXX/web/modules/contrib/commerce/src/Context.php)."