aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Shantanu Singh <[email protected]>2021-06-08 14:47:33 +0530
committerGravatar GitHub <[email protected]>2021-06-08 14:47:33 +0530
commit37390bde74953384145441bbd0d889d7da710755 (patch)
treee1ec6d6dae125d8b47d0328ffcbfb6e605097dd4
parentresolved linting error with if-else (diff)
resolved syntax error
-rw-r--r--bot/exts/evergreen/tic_tac_toe.py12
1 files changed, 7 insertions, 5 deletions
diff --git a/bot/exts/evergreen/tic_tac_toe.py b/bot/exts/evergreen/tic_tac_toe.py
index b50e2b28..dccbad4c 100644
--- a/bot/exts/evergreen/tic_tac_toe.py
+++ b/bot/exts/evergreen/tic_tac_toe.py
@@ -318,13 +318,15 @@ class TicTacToe(Cog):
return
game = self.games[game_id - 1]
+ if game.draw:
+ description = f"{game.winner} vs {game.loser} (draw)\n\n{game.format_board()}"
+ else:
+ description = f"{game.winner} :trophy: vs {game.loser}\n\n{game.format_board()}"
+
embed = discord.Embed(
title=f"Match #{game_id} Game Board",
- if game.draw:
- description = f"{game.winner} vs {game.loser} (draw)\n\n{game.format_board()}"
- else:
- description = f"{game.winner} :trophy: vs {game.loser}\n\n{game.format_board()}"
- )
+ description=description,
+)
await ctx.send(embed=embed)