]> git.openstreetmap.org Git - rails.git/blobdiff - app/controllers/browse_controller.rb
Add a timeout to the change list pages
[rails.git] / app / controllers / browse_controller.rb
index 96cec39437150ee4a43e223734b7512ce39a131d..9aec1060a19b3c836e455c0abcc0dd36c79ec8cc 100644 (file)
@@ -4,7 +4,7 @@ class BrowseController < ApplicationController
   before_filter :authorize_web  
   before_filter :set_locale 
   before_filter { |c| c.check_database_readable(true) }
-  around_filter :timeout, :except => [:start]
+  around_filter :web_timeout, :except => [:start]
 
   def start 
   end
@@ -77,14 +77,4 @@ class BrowseController < ApplicationController
   rescue ActiveRecord::RecordNotFound
     render :action => "not_found", :status => :not_found
   end
-
-private
-
-  def timeout
-    Timeout::timeout(30) do
-      yield
-    end
-  rescue Timeout::Error
-    render :action => "timeout", :status => :request_timeout
-  end
 end