Browse files

call to_a since we are not passing anything to all()

  • Loading branch information...
1 parent 906ef23 commit ba9602b9e7fc02118e5bda3c1330dbd2f6274a09 @tenderlove tenderlove committed Aug 4, 2010
Showing with 1 addition and 1 deletion.
  1. +1 −1 activerecord/lib/active_record/relation/batches.rb
View
2 activerecord/lib/active_record/relation/batches.rb
@@ -73,7 +73,7 @@ def find_in_batches(options = {})
break if records.size < batch_size
if primary_key_offset = records.last.id
- records = relation.where(primary_key.gt(primary_key_offset)).all
+ records = relation.where(primary_key.gt(primary_key_offset)).to_a
else
raise "Primary key not included in the custom select clause"
end

0 comments on commit ba9602b

Please sign in to comment.