Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Only apply app/assets/public middleware if config.serve_static_assets

  • Loading branch information...
commit 0d8112d74d9bbfda76e49c4f670ec2ba7bb8eb8b 1 parent 142d044
@davidjrice authored
Showing with 1 addition and 5 deletions.
  1. +1 −5 railties/lib/rails/application.rb
View
6 railties/lib/rails/application.rb
@@ -234,14 +234,10 @@ def default_middleware_stack
end
if config.serve_static_assets
+ middleware.use ::ActionDispatch::Static, "app/assets/public", false if Rails.env.development?
middleware.use ::ActionDispatch::Static, paths["public"].first, config.static_cache_control
end
- if Rails.env.development?
- # Serve static assets from app/assets/public
- middleware.use ::ActionDispatch::Static, "app/assets/public", false
- end
-
middleware.use ::Rack::Lock unless config.allow_concurrency
middleware.use ::Rack::Runtime
middleware.use ::Rack::MethodOverride unless config.middleware.http_only?

0 comments on commit 0d8112d

Please sign in to comment.
Something went wrong with that request. Please try again.