diff options
Diffstat (limited to 'actionpack/lib/action_controller/caching.rb')
-rw-r--r-- | actionpack/lib/action_controller/caching.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/actionpack/lib/action_controller/caching.rb b/actionpack/lib/action_controller/caching.rb index 21d9c69831..cc5544241e 100644 --- a/actionpack/lib/action_controller/caching.rb +++ b/actionpack/lib/action_controller/caching.rb @@ -247,10 +247,10 @@ module ActionController #:nodoc: end # Called by CacheHelper#cache - def cache_erb_fragment(name = {}, options = {}, &block) + def cache_erb_fragment(block, name = {}, options = {}) unless perform_caching then block.call; return end - buffer = eval("_erbout", block) + buffer = eval("_erbout", block.binding) if cache = read_fragment(name, options) buffer.concat(cache) |