This project is archived and is in readonly mode.
Size reports incorrectly for collections when more than one item is added with build
-
sds
Actually the creation of a new array in the patched version is not needed (select already returns an array), I attach new patch containing this code:
unsaved_records = @target.select { |r| r.new_record? }
unsaved_records.size + count_records
-
Repository
- Tag set to activerecord, bug, patch
(from [474d42538269a141687c7c66bef6575b4682b15d]) Ensure AssociationCollection#size considers all unsaved record. [#305 state:resolved] [sds]
Signed-off-by: Pratik Naik
-
Pratik
- State changed from new to resolved
