Skip to content

Commit f80e493

Browse files
refactor(overmind): add to warning about self transition
1 parent b0765e8 commit f80e493

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/node_modules/overmind/src/statemachine.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ class StateMachine<States extends TStates, State extends TStates = States> {
4545
} else if (process.env.NODE_ENV === 'development' && state !== this.state) {
4646
console.warn(`Overmind Statemachine - You tried to transition into "${state}", but it is not a valid transition. The valid transitions are ${JSON.stringify(transitions[this.state])}`)
4747
} else if (process.env.NODE_ENV === 'development' && state === this.state) {
48-
console.warn(`Overmind Statemachine - You tried to transition into "${state}", but you are already in this state. Do a "match" before running this piece of logic`)
48+
console.warn(`Overmind Statemachine - You tried to transition into "${state}", but you are already in this state. Do a "match" before running this piece of logic or add it as a valid state transition for this state`)
4949
}
5050
}
5151
matches(state) {

0 commit comments

Comments
 (0)