diff options
author | Joshua Peek <josh@joshpeek.com> | 2011-04-21 11:03:56 -0500 |
---|---|---|
committer | Joshua Peek <josh@joshpeek.com> | 2011-04-21 11:03:56 -0500 |
commit | 84f1b83df84d36b75cc7b6d1c84ffd84c6c07260 (patch) | |
tree | 0be91e6419d8ad4d75e301f16552d13bb0a80bfd /actionpack/lib | |
parent | d31af44012a6ba3ac5dbec45417ae9bfb5454d8c (diff) | |
download | rails-84f1b83df84d36b75cc7b6d1c84ffd84c6c07260.tar.gz rails-84f1b83df84d36b75cc7b6d1c84ffd84c6c07260.tar.bz2 rails-84f1b83df84d36b75cc7b6d1c84ffd84c6c07260.zip |
Only include SprocketsHelper into assets context
Diffstat (limited to 'actionpack/lib')
-rw-r--r-- | actionpack/lib/sprockets/railtie.rb | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/actionpack/lib/sprockets/railtie.rb b/actionpack/lib/sprockets/railtie.rb index 2f7f95c44d..ccec65ba95 100644 --- a/actionpack/lib/sprockets/railtie.rb +++ b/actionpack/lib/sprockets/railtie.rb @@ -33,9 +33,10 @@ module Sprockets app.assets = asset_environment(app) - # FIXME: Temp hack for extending Sprockets::Context so ActiveSupport.on_load(:action_view) do - ::Sprockets::Context.send :include, ::ActionView::Helpers::SprocketsHelper + app.assets.context.instance_eval do + include ::ActionView::Helpers::SprocketsHelper + end end app.routes.append do @@ -59,4 +60,4 @@ module Sprockets env end end -end
\ No newline at end of file +end |