diff options
-rw-r--r-- | activerecord/lib/active_record/base.rb | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/activerecord/lib/active_record/base.rb b/activerecord/lib/active_record/base.rb index f5291b180e..a9361f96f0 100644 --- a/activerecord/lib/active_record/base.rb +++ b/activerecord/lib/active_record/base.rb @@ -1014,8 +1014,9 @@ module ActiveRecord #:nodoc: end def all_attributes_exists?(attribute_names) - attribute_names = expand_attribute_names_for_aggregates(attribute_names) - attribute_names.all? { |name| column_methods_hash.include?(name.to_sym) } + expand_attribute_names_for_aggregates(attribute_names).all? { |name| + column_methods_hash.include?(name.to_sym) + } end protected |