Browse files

no need to to_sym the column name, leave it as-is

  • Loading branch information...
1 parent 8b9f16f commit f98d47b1abff6263c3bf0514c64742e15f9a02b3 @tenderlove tenderlove committed Jul 2, 2013
Showing with 1 addition and 1 deletion.
  1. +1 −1 activerecord/lib/active_record/relation/calculations.rb
View
2 activerecord/lib/active_record/relation/calculations.rb
@@ -92,7 +92,7 @@ def sum(*args)
# Person.sum("2 * age")
def calculate(operation, column_name, options = {})
if column_name.is_a?(Symbol) && attribute_alias?(column_name)
- column_name = attribute_alias(column_name).to_sym
+ column_name = attribute_alias(column_name)
end
if has_include?(column_name)

0 comments on commit f98d47b

Please sign in to comment.