Oopsie
This commit is contained in:
@@ -21,3 +21,12 @@ class Game:
|
||||
|
||||
def get_moves(self):
|
||||
return self.moves
|
||||
|
||||
def to_dict(self):
|
||||
return {
|
||||
"white_name": self._white_name,
|
||||
"black_name": self._black_name,
|
||||
"time_control": self._time_control,
|
||||
"increment": self._increments,
|
||||
"moves": self._moves,
|
||||
}
|
||||
@@ -62,7 +62,7 @@ class GameService:
|
||||
self._on_terminated = callback
|
||||
|
||||
def _notify(self):
|
||||
game_data = json.dumps(self._game)
|
||||
game_data = json.dumps(self._game.to_dict())
|
||||
self._on_terminated(game_data)
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user