Permalink
Browse files

no need to compact an already compacted Array

  • Loading branch information...
1 parent 1a77015 commit c8711e4ecd1531db15b6f2d0dbf01fed44904667 @amatsuda amatsuda committed Dec 28, 2011
Showing with 1 addition and 1 deletion.
  1. +1 −1 activerecord/lib/active_record/relation/predicate_builder.rb
@@ -32,7 +32,7 @@ def self.build_from_hash(engine, attributes, default_table)
if values.empty?
array_predicates << attribute.eq(nil)
else
- array_predicates << attribute.in(values.compact).or(attribute.eq(nil))
+ array_predicates << attribute.in(values).or(attribute.eq(nil))
end
else
array_predicates << attribute.in(values)

0 comments on commit c8711e4

Please sign in to comment.