aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJon Leighton <j@jonathanleighton.com>2010-12-23 20:52:56 +0000
committerJon Leighton <j@jonathanleighton.com>2010-12-26 19:38:04 +0000
commit7021b6b851c1567a73eae5e74eba437a52b112bf (patch)
treeab8bbccf3c2abed89b8066c96d71a9f80b4c6084
parentd7a659334cf5b342156682758f971308021deb4a (diff)
downloadrails-7021b6b851c1567a73eae5e74eba437a52b112bf.tar.gz
rails-7021b6b851c1567a73eae5e74eba437a52b112bf.tar.bz2
rails-7021b6b851c1567a73eae5e74eba437a52b112bf.zip
Remove custom_select param from construct_select, as it isn't used
-rw-r--r--activerecord/lib/active_record/associations/through_association_scope.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/activerecord/lib/active_record/associations/through_association_scope.rb b/activerecord/lib/active_record/associations/through_association_scope.rb
index fa84de533f..415fc53e1c 100644
--- a/activerecord/lib/active_record/associations/through_association_scope.rb
+++ b/activerecord/lib/active_record/associations/through_association_scope.rb
@@ -73,9 +73,9 @@ module ActiveRecord
end
end
- def construct_select(custom_select = nil)
- distinct = "DISTINCT #{@reflection.quoted_table_name}.*" if @reflection.options[:uniq]
- custom_select || @reflection.options[:select] || distinct
+ def construct_select
+ @reflection.options[:select] ||
+ @reflection.options[:uniq] && "DISTINCT #{@reflection.quoted_table_name}.*"
end
def construct_joins