diff options
author | Xavier Noria <fxn@hashref.com> | 2009-03-11 13:24:09 +0100 |
---|---|---|
committer | Xavier Noria <fxn@hashref.com> | 2009-03-11 13:24:56 +0100 |
commit | 4bf468cb8b1fadc8b7e0a60944873b5ae57f7691 (patch) | |
tree | 22d2e1f8aaa42451ae51fd59db1b4d992c6e7a7b /railties | |
parent | d088ce5653ad2e19b9ea4c5b12b8b1190b7e8963 (diff) | |
download | rails-4bf468cb8b1fadc8b7e0a60944873b5ae57f7691.tar.gz rails-4bf468cb8b1fadc8b7e0a60944873b5ae57f7691.tar.bz2 rails-4bf468cb8b1fadc8b7e0a60944873b5ae57f7691.zip |
in validations guide, emphasize after_save runs always after more specific after_*s
Diffstat (limited to 'railties')
-rw-r--r-- | railties/guides/source/activerecord_validations_callbacks.textile | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/railties/guides/source/activerecord_validations_callbacks.textile b/railties/guides/source/activerecord_validations_callbacks.textile index 7ce1b80a6a..efa45a7ac6 100644 --- a/railties/guides/source/activerecord_validations_callbacks.textile +++ b/railties/guides/source/activerecord_validations_callbacks.textile @@ -823,6 +823,8 @@ h4. Destroying an Object * DELETE OPERATION * +after_destroy+ +WARNING. +after_save+ runs both on create and update, but always _after_ the more specific callbacks +after_create+ and +after_update+, no matter the order in which the macro calls were executed. + h4. +after_initialize+ and +after_find+ The +after_initialize+ callback will be called whenever an Active Record object is instantiated, either by directly using +new+ or when a record is loaded from the database. It can be useful to avoid the need to directly override your Active Record +initialize+ method. |