From 2e69db18ce2815c25eee64fc2978e7f6b57f6e1f Mon Sep 17 00:00:00 2001 From: Joshua Peek Date: Wed, 28 Jan 2009 21:20:46 -0600 Subject: Only dup local cache values if duplicable [#1653 state:resolved] --- activesupport/lib/active_support/cache/strategy/local_cache.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'activesupport/lib/active_support/cache/strategy') diff --git a/activesupport/lib/active_support/cache/strategy/local_cache.rb b/activesupport/lib/active_support/cache/strategy/local_cache.rb index 621358d701..d83e259a2a 100644 --- a/activesupport/lib/active_support/cache/strategy/local_cache.rb +++ b/activesupport/lib/active_support/cache/strategy/local_cache.rb @@ -41,7 +41,7 @@ module ActiveSupport value else # forcing the value to be immutable - value.dup + value.duplicable? ? value.dup : value end end -- cgit v1.2.3