Browse files

Make sure not to spalt string arguments

  • Loading branch information...
1 parent abae712 commit 7ff131f740d10cad767ab1200f9d089055806090 @lifo lifo committed Jan 2, 2010
Showing with 1 addition and 1 deletion.
  1. +1 −1 activerecord/lib/active_record/relation/query_methods.rb
View
2 activerecord/lib/active_record/relation/query_methods.rb
@@ -116,7 +116,7 @@ def where(*args)
args.first
end
- spawn(@relation.where(*conditions))
+ conditions.is_a?(String) ? spawn(@relation.where(conditions)) : spawn(@relation.where(*conditions))
end
private

0 comments on commit 7ff131f

Please sign in to comment.