diff options
author | Joshua Peek <josh@joshpeek.com> | 2009-04-14 17:06:32 -0500 |
---|---|---|
committer | Joshua Peek <josh@joshpeek.com> | 2009-04-14 17:06:32 -0500 |
commit | d7396b5ca9c066cb16158c02b976dab01f522344 (patch) | |
tree | 84d934d8a5f83af8f749117ac9c9bf2d56660249 /actionpack/lib | |
parent | 1d2686517c4369c3609be166f0d11970c87099b5 (diff) | |
download | rails-d7396b5ca9c066cb16158c02b976dab01f522344.tar.gz rails-d7396b5ca9c066cb16158c02b976dab01f522344.tar.bz2 rails-d7396b5ca9c066cb16158c02b976dab01f522344.zip |
Move reloader middleware in ActionDispatch
Diffstat (limited to 'actionpack/lib')
-rw-r--r-- | actionpack/lib/action_controller.rb | 1 | ||||
-rw-r--r-- | actionpack/lib/action_controller/dispatch/dispatcher.rb | 4 | ||||
-rw-r--r-- | actionpack/lib/action_dispatch.rb | 1 | ||||
-rw-r--r-- | actionpack/lib/action_dispatch/middleware/reloader.rb (renamed from actionpack/lib/action_controller/reloader.rb) | 6 |
4 files changed, 6 insertions, 6 deletions
diff --git a/actionpack/lib/action_controller.rb b/actionpack/lib/action_controller.rb index 9eb7474b55..e52690ebf6 100644 --- a/actionpack/lib/action_controller.rb +++ b/actionpack/lib/action_controller.rb @@ -57,7 +57,6 @@ module ActionController autoload :PolymorphicRoutes, 'action_controller/routing/generation/polymorphic_routes' autoload :RecordIdentifier, 'action_controller/record_identifier' autoload :Redirector, 'action_controller/base/redirect' - autoload :Reloader, 'action_controller/reloader' autoload :Renderer, 'action_controller/base/render' autoload :RequestForgeryProtection, 'action_controller/base/request_forgery_protection' autoload :Rescue, 'action_controller/dispatch/rescue' diff --git a/actionpack/lib/action_controller/dispatch/dispatcher.rb b/actionpack/lib/action_controller/dispatch/dispatcher.rb index 8ed7de4788..bb9d8bd063 100644 --- a/actionpack/lib/action_controller/dispatch/dispatcher.rb +++ b/actionpack/lib/action_controller/dispatch/dispatcher.rb @@ -5,8 +5,8 @@ module ActionController class << self def define_dispatcher_callbacks(cache_classes) unless cache_classes - unless self.middleware.include?(Reloader) - self.middleware.insert_after(ActionDispatch::Failsafe, Reloader) + unless self.middleware.include?(ActionDispatch::Reloader) + self.middleware.insert_after(ActionDispatch::Failsafe, ActionDispatch::Reloader) end ActionView::Helpers::AssetTagHelper.cache_asset_timestamps = false diff --git a/actionpack/lib/action_dispatch.rb b/actionpack/lib/action_dispatch.rb index f36e655c16..bd5a38cc82 100644 --- a/actionpack/lib/action_dispatch.rb +++ b/actionpack/lib/action_dispatch.rb @@ -46,6 +46,7 @@ module ActionDispatch autoload :Failsafe, 'action_dispatch/middleware/failsafe' autoload :ParamsParser, 'action_dispatch/middleware/params_parser' + autoload :Reloader, 'action_dispatch/middleware/reloader' autoload :RewindableInput, 'action_dispatch/middleware/rewindable_input' autoload :MiddlewareStack, 'action_dispatch/middleware/stack' diff --git a/actionpack/lib/action_controller/reloader.rb b/actionpack/lib/action_dispatch/middleware/reloader.rb index 46789309cd..67313e30e4 100644 --- a/actionpack/lib/action_controller/reloader.rb +++ b/actionpack/lib/action_dispatch/middleware/reloader.rb @@ -1,14 +1,14 @@ -module ActionController +module ActionDispatch class Reloader def initialize(app) @app = app end def call(env) - Dispatcher.reload_application + ActionController::Dispatcher.reload_application @app.call(env) ensure - Dispatcher.cleanup_application + ActionController::Dispatcher.cleanup_application end end end |