Skip to content

Conversation

@NelsonFrancisco
Copy link

@NelsonFrancisco NelsonFrancisco commented May 17, 2019

#171 related

When you throw an exception inside an observer the FSM state might be updated:

  • If the error is thrown before one specific observer is called (onTransit) then the state would not change
  • If the error is thrown after onTransit observer, then the state is changed.

This PR makes this consistent, and it always reverts the state.
It basically reverts to the previous state when the exception is thrown IF the current state is different from the previous one, defined in the transition.
Promises supported

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.

1 participant