Skip to content

Commit

Permalink
Remove redundant uniq
Browse files Browse the repository at this point in the history
  • Loading branch information
fcheung authored and NZKoz committed Nov 11, 2008
1 parent cbb38bb commit 78a1839
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion activerecord/lib/active_record/association_preload.rb
Expand Up @@ -312,7 +312,7 @@ def preload_belongs_to_association(records, reflection, preload_options={})
table_name = klass.quoted_table_name
primary_key = klass.primary_key
column_type = klass.columns.detect{|c| c.name == primary_key}.type
ids = id_map.keys.uniq.map do |id|
ids = id_map.keys.map do |id|
if column_type == :integer
id.to_i
elsif column_type == :float
Expand Down

0 comments on commit 78a1839

Please sign in to comment.