diff options
Diffstat (limited to 'railties/lib')
-rw-r--r-- | railties/lib/rails/application.rb | 2 | ||||
-rw-r--r-- | railties/lib/rails/commands/server.rb | 1 |
2 files changed, 1 insertions, 2 deletions
diff --git a/railties/lib/rails/application.rb b/railties/lib/rails/application.rb index a7405aae16..99527bb051 100644 --- a/railties/lib/rails/application.rb +++ b/railties/lib/rails/application.rb @@ -141,8 +141,6 @@ module Rails def default_middleware_stack ActionDispatch::MiddlewareStack.new.tap do |middleware| - middleware.use ::Rails::Rack::ContentLength, config.action_dispatch.x_sendfile_header - if rack_cache = config.action_controller.perform_caching && config.action_dispatch.rack_cache require "action_dispatch/http/rack_cache" middleware.use ::Rack::Cache, rack_cache diff --git a/railties/lib/rails/commands/server.rb b/railties/lib/rails/commands/server.rb index 505a4ca2bd..91c87514cf 100644 --- a/railties/lib/rails/commands/server.rb +++ b/railties/lib/rails/commands/server.rb @@ -78,6 +78,7 @@ module Rails middlewares = [] middlewares << [Rails::Rack::LogTailer, log_path] unless options[:daemonize] middlewares << [Rails::Rack::Debugger] if options[:debugger] + middlewares << [Rails::Rack::ContentLength] Hash.new(middlewares) end |