Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

multiple actions for :on option with after_commit and after_rollback #9356

Merged

Conversation

senny
Copy link
Member

@senny senny commented Feb 21, 2013

This is the feature requested in #988.

It simply adds the possibility to supply multiple actions for the :on parameter when defining after_commit and after_rollback callbacks.

after_commit :do_foo_bar, :on [:create, :update]
after_commit :do_bar_baz, :on [:update, :destroy]

@senny
Copy link
Member Author

senny commented Feb 21, 2013

@rafaelfranca @carlosantoniodasilva could you take a look?

@steveklabnik
Copy link
Member

Looks good to me, but I'm no AR master.

steveklabnik added a commit that referenced this pull request Feb 24, 2013
…mmit

multiple actions for :on option with `after_commit` and `after_rollback`
@steveklabnik steveklabnik merged commit c3d001b into rails:master Feb 24, 2013
@steveklabnik
Copy link
Member

Checked it out again, read it closely, seems good. :D

@sikachu
Copy link
Member

sikachu commented Feb 24, 2013

Would you mind submit a guide update for this? Thanks!

@sikachu
Copy link
Member

sikachu commented Feb 24, 2013

(Oh, and that could go to docrails if you want to get it merged fast.)

@senny senny deleted the 988_multiple_actions_for_after_commit branch February 24, 2013 16:32
@senny
Copy link
Member Author

senny commented Feb 24, 2013

@sikachu I'll update the guides.

@rafaelfranca
Copy link
Member

Was the guides updated?

@senny
Copy link
Member Author

senny commented Feb 24, 2013

@rafaelfranca not yet. It's on my todo list

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants