1
0
Fork 0
mirror of https://github.com/myned/modufur.git synced 2024-11-01 21:02:38 +00:00

Fix(?) reactions causing bot to exit on error

This commit is contained in:
Myned 2019-01-20 01:35:02 -05:00
parent 85fef7983e
commit 21dbd9a406

View file

@ -180,10 +180,10 @@ def ci(pos, n):
return (phat + z*z/(2*n) - z * math.sqrt((phat*(1-phat)+z*z/(4*n))/n))/(1+z*z/n) return (phat + z*z/(2*n) - z * math.sqrt((phat*(1-phat)+z*z/(4*n))/n))/(1+z*z/n)
async def add_reaction(message, reaction, error=err.NotFound): async def add_reaction(message, reaction, errors=(err.NotFound, err.Forbidden)):
sent = False sent = False
with suppress(error): with suppress(errors):
await message.add_reaction(reaction) await message.add_reaction(reaction)
sent = True sent = True