From 4bf4efe712489090fca4ce14be9cbe7637f4d511 Mon Sep 17 00:00:00 2001 From: Dmitriy Zaporozhets Date: Sun, 20 Nov 2011 22:32:12 +0200 Subject: decorators & tree model --- app/controllers/application_controller.rb | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'app/controllers/application_controller.rb') diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb index 95d94035448..b37deafdb4e 100644 --- a/app/controllers/application_controller.rb +++ b/app/controllers/application_controller.rb @@ -84,4 +84,10 @@ class ApplicationController < ActionController::Base nil end end + + def no_cache_headers + response.headers["Cache-Control"] = "no-cache, no-store, max-age=0, must-revalidate" + response.headers["Pragma"] = "no-cache" + response.headers["Expires"] = "Fri, 01 Jan 1990 00:00:00 GMT" + end end -- cgit v1.2.1