-
Notifications
You must be signed in to change notification settings - Fork 92
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
fire_state_event! #66
Comments
We've been using the following pattern:
This raises an exception, essentially triggering the bang version of the event. Hope this helps. |
Still looking for the implementation, but there's some documentation here: https://github.com/pluginaweek/state_machine#explicit-vs-implicit-event-transitions |
Found the implementation of implicit / attribute-based state transitions here: state_machines/lib/state_machines/machine.rb Line 1051 in c94d690
It looks like there are some caveats with implicit transitions documented elsewhere: state_machines/lib/state_machines/machine.rb Line 1204 in c94d690
I didn't see any support for passing arguments (ex: an attribute like Therefore I would also be in favor of defining a state_machines/lib/state_machines/event.rb Line 224 in a8e18f6
|
I can't find the bang version of
fire_state_event
(throw error instead of returning false). What is the best way to add this feature?The text was updated successfully, but these errors were encountered: