]> git.openstreetmap.org Git - rails.git/blobdiff - app/controllers/application_controller.rb
Make database offline mode work
[rails.git] / app / controllers / application_controller.rb
index 2d137cc41d7be704914a395899e4067adf1c2f22..ec2f381fc8b971448853385692c1b339c3ff3b04 100644 (file)
@@ -3,7 +3,12 @@ class ApplicationController < ActionController::Base
   protect_from_forgery
 
   if STATUS == :database_readonly or STATUS == :database_offline
   protect_from_forgery
 
   if STATUS == :database_readonly or STATUS == :database_offline
-    session :off
+    after_filter :clear_session
+    wrap_parameters false
+
+    def clear_session
+      session.clear
+    end
 
     def self.cache_sweeper(*sweepers)
     end
 
     def self.cache_sweeper(*sweepers)
     end