Skip to content

Conversation

brainopia
Copy link
Contributor

Currently if cookie is set to the same value then it will be streamed back to client. But it's needed only if there is expires option. Also when deleting unexisting cookie the deletion will be streamed back also.

I've improved these edge cases and provided a couple of small improvements of code nearby.

@josevalim
Copy link
Contributor

Just as note, we already do this for session. Should we do this for cookies automatically as well? /cc @jeremy

@brainopia
Copy link
Contributor Author

I want to note that session are streamed back too even if not changed, at least cookie store. Because rails cookie store reimplements set_cookie method.

I noticed it when I was fixing #3047, #2483 and I needed to use cookie jar in AbstractStore the same way as currently in CookieStore and one test failed which checked exactly streaming issue for ActiveRecord store.

josevalim added a commit that referenced this pull request Apr 30, 2012
@josevalim josevalim merged commit 09de707 into rails:master Apr 30, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants