Skip to content

Commit

Permalink
[Discord] Optimize ChessMatch task
Browse files Browse the repository at this point in the history
  • Loading branch information
Harmon758 committed Nov 15, 2023
1 parent d9da112 commit 291c258
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions Discord/cogs/chess.py
Original file line number Diff line number Diff line change
Expand Up @@ -288,12 +288,11 @@ async def resign(self):
await self.update_match_embed(resigned = True)

async def match_task(self):
self.message = await self.ctx.embed_send("Loading..")

if self.ctx.interaction:
self.message = await self.message.fetch()
self.ctx = await self.bot.get_context(self.ctx.message)

self.message = await self.ctx.embed_send("Loading..")

await self.update_match_embed()

while not self.ended.is_set():
Expand Down

0 comments on commit 291c258

Please sign in to comment.