mirror of
https://github.com/NohamR/TransmissionBot.git
synced 2025-05-24 14:22:00 +00:00
bugfix
missed some reaction cleanup when you fast-react to print the legend
This commit is contained in:
parent
00a05a21c9
commit
d6cd84dbcf
13
bot.py
13
bot.py
@ -752,7 +752,10 @@ async def summary(context, *, content="", repeat_msg_key=None):
|
|||||||
async for user in r.users():
|
async for user in r.users():
|
||||||
if user.id in WHITELIST:
|
if user.id in WHITELIST:
|
||||||
if str(r.emoji) == '📜':
|
if str(r.emoji) == '📜':
|
||||||
await msg.clear_reaction('📜')
|
if repeat_msg_key:
|
||||||
|
await msg.clear_reaction('📜')
|
||||||
|
else:
|
||||||
|
await msg.clear_reactions()
|
||||||
await legend(context)
|
await legend(context)
|
||||||
return
|
return
|
||||||
elif str(r.emoji) == '❎':
|
elif str(r.emoji) == '❎':
|
||||||
@ -1069,10 +1072,16 @@ async def list_transfers(context, *, content="", repeat_msg_key=None):
|
|||||||
try:
|
try:
|
||||||
reaction, user = await client.wait_for('reaction_add', timeout=60.0 if not repeat_msg_key else REPEAT_MSGS[repeat_msg_key]['freq'], check=check)
|
reaction, user = await client.wait_for('reaction_add', timeout=60.0 if not repeat_msg_key else REPEAT_MSGS[repeat_msg_key]['freq'], check=check)
|
||||||
except asyncio.TimeoutError:
|
except asyncio.TimeoutError:
|
||||||
|
if not repeat_msg_key:
|
||||||
|
await msg.clear_reactions()
|
||||||
|
return
|
||||||
pass
|
pass
|
||||||
else:
|
else:
|
||||||
if str(reaction.emoji) == '📜':
|
if str(reaction.emoji) == '📜':
|
||||||
await msg.clear_reaction('📜')
|
if repeat_msg_key:
|
||||||
|
await msg.clear_reaction('📜')
|
||||||
|
else:
|
||||||
|
await msg.clear_reactions()
|
||||||
await legend(context)
|
await legend(context)
|
||||||
return
|
return
|
||||||
elif str(reaction.emoji) == '🖨':
|
elif str(reaction.emoji) == '🖨':
|
||||||
|
Loading…
x
Reference in New Issue
Block a user