Sha256: 50bbeed42c079a5927430f5870ca0a82bf5e944139540c79a4829f1a489079c1
Contents?: true
Size: 388 Bytes
Versions: 37
Compression:
Stored size: 388 Bytes
Contents
module Scrivito class DisableBrowserCacheForUiMiddleware def initialize(app) @app = app end def call(env) status, headers, response = @app.call(env) editing_context = EditingContextMiddleware.from_env(env) if editing_context.authenticated_editor? headers['Cache-Control'] = 'no-store, must-revalidate' end [status, headers, response] end end end
Version data entries
37 entries across 37 versions & 1 rubygems