Fix crash when game ends

This commit is contained in:
2024-05-14 17:17:37 +02:00
parent 2ec8a810d7
commit c880e75e0d
+2 -2
View File
@@ -30,7 +30,7 @@ class Game(Serializable):
started: bool
ended: bool
default_health = 50
default_health = 1
current_turn: Team | None
@@ -188,7 +188,7 @@ class Game(Serializable):
)
def end_game(self):
self.lobby.remove(self)
self.lobby.games.remove(self)
self.ended = True
def kill_team(self, team: Team):