Stpn
Stpn

Reputation: 6394

Using multiple callbacks for Rails (:after_commit)?

Would there be conflicts if I have multiple callbacks of the same nature in Rails? Like several after_commit for the same model?

I guess I can join them into one method, but for readability reasons, I would rather not..

Upvotes: 15

Views: 8217

Answers (1)

iouri
iouri

Reputation: 2929

No they will be executed one after another

after_commit :callback_one, :callback_two

Upvotes: 31

Related Questions