anonymous classes have blank names on ruby 1.8

This commit is contained in:
Aaron Patterson 2011-03-02 10:23:04 -08:00
parent 1f2e7214aa
commit 72405efe64
1 changed files with 1 additions and 1 deletions

View File

@ -537,7 +537,7 @@ module ActiveSupport #:nodoc:
def []=(key, value)
return unless key.respond_to?(:name)
raise(ArgumentError, 'anonymous classes cannot be cached') unless key.name
raise(ArgumentError, 'anonymous classes cannot be cached') if key.name.blank?
@store[key.name] = value
end