Jump to content

noCache cookie when adding to cart expires incorrectly


Recommended Posts

\IPS\nexus\Package, L2349, you have a comment saying


Set the cookie for 20 minutes - if the guest hasn't checked out by then they may no longer see their cart on every page but as long as their session is still valid they will still be able to check out.

However, if this case does get hit, there is also a risk that this user's page gets cached, so the user's cart gets shown to other guests, which would be kinda bad. Also, theoretically they won't be able to check out because the cart page may also be cached as empty or incorrect, though that adds additional constraints so is slightly less likely.

Given that this hasn't been hit throughout the whole life of guest page caching being an actual feature, it's probably not super critical - it's probably super rare that someone adds stuff to their cart, then browses the site for 20 mins+ without clearing it - but I don't see any downside to setting the cookie for the session lifetime, to be consistent with everywhere else, and this does matter when caching is pushed to the CDN.

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...