You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[`ActiveRecord.after_all_transactions_commit`][] is a callback that allows you to run code after all the current transactions have been successfully committed to the database.
# An email will be sent after the outermost transaction is committed.
1368
+
end
1369
+
end
1370
+
end
1371
+
end
1372
+
```
1373
+
1374
+
A callback registered to `after_all_transactions_commit` will be triggered after the outermost transaction is committed. If any of the currently open transactions is rolled back, the block is never called.
1375
+
In the event that there are no open transactions at the time a callback is registered, the block will be yielded immediately.
0 commit comments