diff options
author | Sean Griffin <sean@thoughtbot.com> | 2015-01-10 11:57:14 -0700 |
---|---|---|
committer | Sean Griffin <sean@thoughtbot.com> | 2015-01-10 12:07:46 -0700 |
commit | 4d5e6607899832bde1365bdd4f7617a24bca4561 (patch) | |
tree | ff73a81700a04e57a16d7edef778c55207e70e61 /activerecord/CHANGELOG.md | |
parent | 89470bbc5ea4e1375dc948b0629a419c1ad5c4f5 (diff) | |
download | rails-4d5e6607899832bde1365bdd4f7617a24bca4561.tar.gz rails-4d5e6607899832bde1365bdd4f7617a24bca4561.tar.bz2 rails-4d5e6607899832bde1365bdd4f7617a24bca4561.zip |
Don't attempt to save dirty attributes which are not persistable
This sets a precident for how we handle `attribute` calls, which aren't
backed by a database column. We should not take this as a conscious
decision on how to handle them, and this can change when we make
`attribute` public if we have better ideas in the future.
As the composed attributes API gets fleshed out, I expect the
`persistable_attributes` method to change to
`@attributes.select(&:persistable).keys`, or some more performant
variant there-of. This can probably go away completely once we fully
move dirty checking into the attribute objects once it gets moved up to
Active Model.
Fixes #18407
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 c677c41727..c5f0e5022a 100644 --- a/activerecord/CHANGELOG.md +++ b/activerecord/CHANGELOG.md @@ -1,3 +1,10 @@ +* `attribute_will_change!` will no longer cause non-persistable attributes to + be sent to the database. + + Fixes #18407. + + *Sean Griffin* + * Remove support for the `protected_attributes` gem. *Carlos Antonio da Silva*, *Roberto Miranda* |