Switch all state machine route mappints from matching (event, fromState) to (fromState, event)
This commit is contained in:
committed by
Stefan Ceriu
parent
84ec5a37ff
commit
712f087b36
@@ -104,8 +104,8 @@ class AppCoordinatorStateMachine {
|
||||
|
||||
// Transitions with associated values need to be handled through `addRouteMapping`
|
||||
stateMachine.addRouteMapping { event, fromState, _ in
|
||||
switch (event, fromState) {
|
||||
case (.signOut(let isSoft, let disableAppLock), _):
|
||||
switch (fromState, event) {
|
||||
case (_, .signOut(let isSoft, let disableAppLock)):
|
||||
return .signingOut(isSoft: isSoft, disableAppLock: disableAppLock)
|
||||
default:
|
||||
return nil
|
||||
|
||||
Reference in New Issue
Block a user