diff --git a/stateMachine.py b/stateMachine.py index 911e7f1..6577740 100644 --- a/stateMachine.py +++ b/stateMachine.py @@ -54,7 +54,7 @@ class State: def next(self, signal): t = (self, signal) - return self.stateMachine.transitionTable[t] + return self if t not in self.stateMachine.transitionTable else self.stateMachine.transitionTable[t] def __str__(self): return self.name