diff options
author | Joshua Peek <josh@joshpeek.com> | 2010-01-04 19:38:56 -0600 |
---|---|---|
committer | Joshua Peek <josh@joshpeek.com> | 2010-01-04 19:40:16 -0600 |
commit | 76b5f18feba3f1d0507b4c4ec34d11d9bb1c493c (patch) | |
tree | 0b759bfcb59817b9a511b07f0be4743863ab8b9e /actionpack/lib/action_controller/railtie.rb | |
parent | 56b28ec8d6b226414fb240d4d4f6f1bd25292dc9 (diff) | |
download | rails-76b5f18feba3f1d0507b4c4ec34d11d9bb1c493c.tar.gz rails-76b5f18feba3f1d0507b4c4ec34d11d9bb1c493c.tar.bz2 rails-76b5f18feba3f1d0507b4c4ec34d11d9bb1c493c.zip |
Default middleware stack needs to be available at configuration time
Diffstat (limited to 'actionpack/lib/action_controller/railtie.rb')
-rw-r--r-- | actionpack/lib/action_controller/railtie.rb | 20 |
1 files changed, 0 insertions, 20 deletions
diff --git a/actionpack/lib/action_controller/railtie.rb b/actionpack/lib/action_controller/railtie.rb index f861d12905..6b94c32b2a 100644 --- a/actionpack/lib/action_controller/railtie.rb +++ b/actionpack/lib/action_controller/railtie.rb @@ -23,26 +23,6 @@ module ActionController app.reload_routes! end - # Include middleware to serve up static assets - initializer "action_controller.initialize_static_server" do |app| - if app.config.serve_static_assets - app.config.middleware.use(ActionDispatch::Static, Rails.public_path) - end - end - - initializer "action_controller.initialize_middleware_stack" do |app| - middleware = app.config.middleware - middleware.use(::Rack::Lock, :if => lambda { ActionController::Base.allow_concurrency }) - middleware.use(::Rack::Runtime) - middleware.use(ActionDispatch::ShowExceptions, lambda { ActionController::Base.consider_all_requests_local }) - middleware.use(ActionDispatch::Callbacks, lambda { ActionController::Dispatcher.prepare_each_request }) - middleware.use(lambda { ActionController::Base.session_store }, lambda { ActionController::Base.session_options }) - middleware.use(ActionDispatch::ParamsParser) - middleware.use(::Rack::MethodOverride) - middleware.use(::Rack::Head) - middleware.use(ActionDispatch::StringCoercion) - end - initializer "action_controller.initialize_framework_caches" do ActionController::Base.cache_store ||= RAILS_CACHE end |