-
-
Notifications
You must be signed in to change notification settings - Fork 6.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove set-cookie header on custom.css #16314
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This does not seem to actually work. I think I already had investigated session_options[:skip]
in the past and it only worked with Rails 4?
In any case, I'm currently investigating why a session is accessed at all in the first place in this controller.
ok so, Cookies are initially set because of the Now, because of the EDIT: found why the |
Adding the following avoids a session cookie being sent in all cases: skip_before_action :update_user_sign_in
skip_before_action :set_session_activity
skip_around_action :set_locale At this point, we may want to have the controller use another base controller class entirely, but this should be enough for the time being. More generally, we might want to review all controllers to ensure we are not needlessly updating/re-sending the session cookie. |
|
||
before_action :set_cache_headers | ||
|
||
def show | ||
expires_in 3.minutes, public: true | ||
request.session_options[:skip] = true |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think it's of any use, but it doesn't hurt either.
* Remove set-cookie header on custom.css * Additional fix for set-cookie
* Remove set-cookie header on custom.css * Additional fix for set-cookie
/custom.css
intended to be cached, But was not cached by nginx, cdn because it hasSet-Cookie
header.This commit will fix that problem.