diff options
author | Daniel Schierbeck <daniel.schierbeck@gmail.com> | 2011-08-25 12:36:11 +0200 |
---|---|---|
committer | Daniel Schierbeck <daniel.schierbeck@gmail.com> | 2011-08-25 12:36:11 +0200 |
commit | b59aa358bb311d3d06c5df856a1d57124b857d5a (patch) | |
tree | 6ab52cd00611b86b861d12afbce7c7e61fdc2abe | |
parent | 68424fb1cf45acda3ad1daef30136f3bcd4f9f9d (diff) | |
download | rails-b59aa358bb311d3d06c5df856a1d57124b857d5a.tar.gz rails-b59aa358bb311d3d06c5df856a1d57124b857d5a.tar.bz2 rails-b59aa358bb311d3d06c5df856a1d57124b857d5a.zip |
Make Sprockets::Helpers::RailsHelper#debug_assets? more readable
-rw-r--r-- | actionpack/lib/sprockets/helpers/rails_helper.rb | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/actionpack/lib/sprockets/helpers/rails_helper.rb b/actionpack/lib/sprockets/helpers/rails_helper.rb index 53cc5ec019..bc1ab3c52a 100644 --- a/actionpack/lib/sprockets/helpers/rails_helper.rb +++ b/actionpack/lib/sprockets/helpers/rails_helper.rb @@ -58,10 +58,10 @@ module Sprockets private def debug_assets? - Rails.application.config.assets.allow_debugging && - (Rails.application.config.assets.debug || - params[:debug_assets] == '1' || - params[:debug_assets] == 'true') + config = Rails.application.config.assets + param = params[:debug_assets] + + config.allow_debugging && (config.debug || param == '1' || param == 'true') end # Override to specify an alternative prefix for asset path generation. |