From 2f66b9a76c955fb5deb16f088986f13dadef6852 Mon Sep 17 00:00:00 2001 From: Neeraj Singh Date: Thu, 9 Sep 2010 13:11:09 -0400 Subject: remove unnecessary call if operation is count then column_name will never be blank --- activerecord/lib/active_record/relation/calculations.rb | 1 - 1 file changed, 1 deletion(-) (limited to 'activerecord/lib/active_record/relation') diff --git a/activerecord/lib/active_record/relation/calculations.rb b/activerecord/lib/active_record/relation/calculations.rb index a80ac40a2c..a09f694fb3 100644 --- a/activerecord/lib/active_record/relation/calculations.rb +++ b/activerecord/lib/active_record/relation/calculations.rb @@ -175,7 +175,6 @@ module ActiveRecord end distinct = options[:distinct] || distinct - column_name = :all if column_name.blank? && operation == "count" if @group_values.any? return execute_grouped_calculation(operation, column_name) -- cgit v1.2.3