diff options
author | Brent Wheeldon & Nick Monje <pair+brent+nmonje@pivotallabs.com> | 2012-06-22 12:09:48 -0400 |
---|---|---|
committer | Ben Moss <pair+bmoss@pivotallabs.com> | 2012-07-20 17:37:57 -0400 |
commit | 9feda929409ab687befaed8d1c9878d94e955adc (patch) | |
tree | 5deafb5e134315050c59e059a71d18ec6915e655 /activerecord/CHANGELOG.md | |
parent | 215d41d802637520129cb7551b35faca72873143 (diff) | |
download | rails-9feda929409ab687befaed8d1c9878d94e955adc.tar.gz rails-9feda929409ab687befaed8d1c9878d94e955adc.tar.bz2 rails-9feda929409ab687befaed8d1c9878d94e955adc.zip |
AR has a subclass of AM:PresenceValidator.
This allows us to mark the parent object as invalid if all associated objects
in a presence validated association are marked for destruction.
See: https://github.com/rails/rails/issues/6812
Diffstat (limited to 'activerecord/CHANGELOG.md')
-rw-r--r-- | activerecord/CHANGELOG.md | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/activerecord/CHANGELOG.md b/activerecord/CHANGELOG.md index a965fe0494..f41ccfe56f 100644 --- a/activerecord/CHANGELOG.md +++ b/activerecord/CHANGELOG.md @@ -31,6 +31,13 @@ *kennyj* +* Changed validates_presence_of on an association so that children objects + do not validate as being present if they are marked for destruction. This + prevents you from saving the parent successfully and thus putting the parent + in an invalid state. + + *Nick Monje & Brent Wheeldon* + * `FinderMethods#exists?` now returns `false` with the `false` argument. *Egor Lynko* |