Skip to content

Commit 78a1839

Browse files
fcheungNZKoz
authored andcommitted
Remove redundant uniq
1 parent cbb38bb commit 78a1839

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

activerecord/lib/active_record/association_preload.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -312,7 +312,7 @@ def preload_belongs_to_association(records, reflection, preload_options={})
312312
table_name = klass.quoted_table_name
313313
primary_key = klass.primary_key
314314
column_type = klass.columns.detect{|c| c.name == primary_key}.type
315-
ids = id_map.keys.uniq.map do |id|
315+
ids = id_map.keys.map do |id|
316316
if column_type == :integer
317317
id.to_i
318318
elsif column_type == :float

0 commit comments

Comments
 (0)