change from sync to async and from flask to quart
Build and Push Docker Container / build-and-push (push) Successful in 1m35s
Build and Push Docker Container / build-and-push (push) Successful in 1m35s
This commit is contained in:
+3
-3
@@ -92,7 +92,7 @@ class GameBoard:
|
||||
|
||||
self._set_turn(game_data["turn"])
|
||||
|
||||
def start_game(self, game_data:dict):
|
||||
async def start_game(self, game_data:dict):
|
||||
self.init_snakes = len(game_data['board']['snakes'])
|
||||
|
||||
def end_game(self, game_data:dict):
|
||||
@@ -134,7 +134,7 @@ class GameBoard:
|
||||
|
||||
return {"name": self.type, "is_ladder": self.is_ladder}
|
||||
|
||||
def save(self, store_class, **kwargs):
|
||||
async def save(self, store_class, **kwargs):
|
||||
store = store_class(**kwargs)
|
||||
store.save(self)
|
||||
await store.save(self)
|
||||
del store
|
||||
|
||||
Reference in New Issue
Block a user