-
Notifications
You must be signed in to change notification settings - Fork 154
Using `on`
Kris Leech edited this page May 22, 2014
·
4 revisions
class BidsController < ApplicationController
def create
@service = MyService.new(service_params)
# subscribe...
@service.run
@service.on(:successful) { redirect_to ... }
@service.on(:failed) { render ... }
end
end
Need to ask a question? Please ask on StackOverflow tagging the question with wisper.
Found a bug? Please report it on the Issue tracker.