diff options
author | Robert Whitney <robertj.whitney@gmail.com> | 2013-03-09 12:34:32 -0500 |
---|---|---|
committer | Robert Whitney <robertj.whitney@gmail.com> | 2013-03-09 13:10:56 -0500 |
commit | 3dffa0d2331a5e25bac2b046f81baac7f0535d68 (patch) | |
tree | 2097cee06b2ce4006b844b2a03f927686d9ffe5f /railties/test | |
parent | 0b93c259fa945c088bc9c6f64621c9976e58bf75 (diff) | |
download | rails-3dffa0d2331a5e25bac2b046f81baac7f0535d68.tar.gz rails-3dffa0d2331a5e25bac2b046f81baac7f0535d68.tar.bz2 rails-3dffa0d2331a5e25bac2b046f81baac7f0535d68.zip |
Update documentation for collection<< to reflect << on new records.
collection<< does not automatically fire update sql unless the parent object
is not a new record (and thus has a primary key).
eg:
p = Post.new
p.comments << Comment.new
does not call update sql until:
p.save
at which point it saves the parent object and then the collection object.
changes that to the
Diffstat (limited to 'railties/test')
0 files changed, 0 insertions, 0 deletions