Closed cjsanchezBW closed 2 months ago
I looked through the code and found that in the apps\storefront\src\pages\Login\index.tsx file, in line 131, there's a block of code that runs a deleteCart function when the user logs out.
I am working on a customized buyer portal. For my project we do want the persisted cart to work. Would it cause issues to remove that code that deletes the cart at logout?
@cjsanchezBW The carts are deleted by default because I'm afraid you'll still lose the cart after 1 re-login. This is a known issue within the BCs storefront APIs that is currently in the feature request status. Closing since this is just not supported yet
@bc-victor What do you mean by: "The carts are deleted by default because I'm afraid you'll still lose the cart after 1 re-login."
I tested removing the code that deletes the cart and I was able to logout and back in and keep my cart's contents without issues.
apps\storefront\src\pages\Login\index.tsx file, in line 131
@cjsanchezBW according to our research, these carts will be lost between authentication processes. If your findings are persistent throughout your development please let us know so I can file this behaviour
@cjsanchezBW if i remove code await deleteCart(deleteQuery); on same browser it is working fine But let's example , i m doing logout and then open incognito window and login with same user, it should be preserve same cart but does not doing that.
Please fill out this template to help us diagnose and address your issue effectively.
Type: (Select one)
Summary:
Expected Behavior:
Actual Behavior:
Steps to Reproduce (Bug Reports Only):
Additional Information:
Version: