1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

Don't rememoize if already frozen

This commit is contained in:
Jeremy Kemper 2008-07-27 21:45:55 -07:00
parent eb256718c3
commit ae6105ef01

View file

@ -11,10 +11,9 @@ module ActiveSupport
def freeze_with_memoizable
methods.each do |method|
if m = method.to_s.match(/^_unmemoized_(.*)/)
send(m[1])
end
end
__send__($1) if method.to_s =~ /^_unmemoized_(.*)/
end unless frozen?
freeze_without_memoizable
end
end