1
0
Fork 0
mirror of https://github.com/mperham/sidekiq.git synced 2022-11-09 13:52:34 -05:00

Add private to Sidekiq Web UI Cache-Control to prevent request collapsing (#4967)

This commit is contained in:
Shaun Bennett 2021-08-14 12:46:15 -04:00 committed by GitHub
parent 20f4babd2d
commit 13e2b564c8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View file

@ -68,7 +68,7 @@ module Sidekiq
end
def json(payload)
[200, {"Content-Type" => "application/json", "Cache-Control" => "no-store"}, [Sidekiq.dump_json(payload)]]
[200, {"Content-Type" => "application/json", "Cache-Control" => "private, no-store"}, [Sidekiq.dump_json(payload)]]
end
def initialize(env, block)

View file

@ -314,7 +314,7 @@ module Sidekiq
# rendered content goes here
headers = {
"Content-Type" => "text/html",
"Cache-Control" => "no-store",
"Cache-Control" => "private, no-store",
"Content-Language" => action.locale,
"Content-Security-Policy" => CSP_HEADER
}