diff options
author | Rafael França <rafaelmfranca@gmail.com> | 2019-04-23 11:14:54 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-04-23 11:14:54 -0400 |
commit | 581e15f26d04fe4c61170a32cb2ec823e013eb7b (patch) | |
tree | 6861fea94ee95299e36a79f2e1094a0835e333f7 /guides | |
parent | 3d0118f6d1ceaae48d1cdd70915b69da2871a735 (diff) | |
parent | 0c349abeb036d02c5e32ff4a84d095f5b5b6bdb2 (diff) | |
download | rails-581e15f26d04fe4c61170a32cb2ec823e013eb7b.tar.gz rails-581e15f26d04fe4c61170a32cb2ec823e013eb7b.tar.bz2 rails-581e15f26d04fe4c61170a32cb2ec823e013eb7b.zip |
Merge pull request #36063 from albertoalmagro/finish-documentation-for-after-save-commit
Remove reminiscences from previous documentation
Diffstat (limited to 'guides')
-rw-r--r-- | guides/source/active_record_callbacks.md | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/guides/source/active_record_callbacks.md b/guides/source/active_record_callbacks.md index 8f54e78224..617f81d37b 100644 --- a/guides/source/active_record_callbacks.md +++ b/guides/source/active_record_callbacks.md @@ -495,11 +495,3 @@ end >> @user.save => User was saved to database ``` - -To register callbacks for both create and destroy actions, use `after_commit` instead. - -```ruby -class User < ApplicationRecord - after_commit :log_user_saved_to_db, on: [:create, :destroy] -end -``` |