From af845f08ad4d6054807d485003157b5cde0e31ba Mon Sep 17 00:00:00 2001 From: Simone Pierazzini Date: Sat, 25 Nov 2023 08:21:31 +0100 Subject: [PATCH] fix handler name resolution --- tng/game/fsm.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tng/game/fsm.py b/tng/game/fsm.py index 8f718e0..a975233 100644 --- a/tng/game/fsm.py +++ b/tng/game/fsm.py @@ -17,7 +17,7 @@ class IllegalMove(ValueError): class TNGFSM: def apply(self, game: Game, move: Move) -> Game: - handler = getattr(self, f'{game.phase.value}_{move.param.move}') + handler = getattr(self, f'{game.phase.value}_{move.param.move.value}') return handler(game, move.player, move.param)