Skip to content
Discussion options

You must be logged in to vote

Maybe you only need to use resave: true instead touch():

"Depending on your store this may be necessary, but it can also create race conditions where a client makes two parallel requests to your server and changes made to the session in one request may get overwritten when the other request ends, even if it made no changes (this behavior also depends on what store you're using).
The default value is true, but using the default has been deprecated, as the default will change in the future. Please research into this setting and choose what is appropriate to your use-case. Typically, you'll want false.
How do I know if this is necessary for my store? The best way to know is to check with you…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by bjohansebas
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #823 on May 16, 2025 02:06.