Permalink
Browse files

scoped.where_values_hash is never nil

  • Loading branch information...
1 parent 57f5fe1 commit c6e0433ca3520e9bc999f70840d82a76b9470873 @jonleighton jonleighton committed Dec 23, 2010
Showing with 1 addition and 1 deletion.
  1. +1 −1 activerecord/lib/active_record/associations/association_collection.rb
View
2 activerecord/lib/active_record/associations/association_collection.rb
@@ -488,7 +488,7 @@ def create_record(attrs, &block)
ensure_owner_is_persisted!
transaction do
- with_scope(:create => @scope[:create].merge(scoped.where_values_hash || {})) do
+ with_scope(:create => @scope[:create].merge(scoped.where_values_hash)) do
build_record(attrs, &block)
end
end

0 comments on commit c6e0433

Please sign in to comment.