Skip to content

Commit

Permalink
fix(events): Don’t use const enum for better backwards compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
delucis committed Aug 22, 2021
1 parent d56d209 commit d54af1f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/plugins/events/events.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import type { State, Ctx, PlayerID, Game, ActivePlayersArg } from '../../types';
import { automaticGameEvent } from '../../core/action-creators';
import { GameMethod } from '../../core/game-methods';

const enum Errors {
enum Errors {
CalledOutsideHook = 'Events must be called from moves or the `onBegin`, `onEnd`, and `onMove` hooks.\n' +
'This error probably means you called an event from other game code, like an `endIf` trigger or one of the `turn.order` methods.',

Expand Down

0 comments on commit d54af1f

Please sign in to comment.