From 4a2b3275a167d6452c4c6b4453bc7406d13e8377 Mon Sep 17 00:00:00 2001 From: Joshua Peek Date: Tue, 21 Jun 2011 09:38:25 -0500 Subject: Assign Rails.cache to sprockets --- actionpack/lib/sprockets/railtie.rb | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'actionpack') diff --git a/actionpack/lib/sprockets/railtie.rb b/actionpack/lib/sprockets/railtie.rb index 38eb00ce01..ab5101f6fc 100644 --- a/actionpack/lib/sprockets/railtie.rb +++ b/actionpack/lib/sprockets/railtie.rb @@ -63,6 +63,10 @@ module Sprockets env.logger = Rails.logger + if env.respond_to?(:cache) + env.cache = Rails.cache + end + if assets.compress # temporarily hardcode default JS compressor to uglify. Soon, it will work # the same as SCSS, where a default plugin sets the default. -- cgit v1.2.3