commerce
commerce copied to clipboard
OrderCloud provider: ordercloud.cart cookie is not cleaned up after checkout
I am not sure if this is by design for all commerce providers or just with the OrderCloud provider. What I found is that the "ordercloud.cart" cookie (which is the cart/order ID from OC) is still left after the cart has been converted into an order (after a successful checkout). This causes problem for new cart operations because it still re-uses the same OC cart (now it's an order). Some operations are allowed like add/remove lineitems (which is still wrong/dangerous to change the lineitems from an placed order) while others are not (like re-calculate the cart total).
So should the cookie(s), at least the ordercloud.cart, be cleaned programmatically after checkout?