From 21dbd9a4063061065f79c6acc3323d9a8abb93b7 Mon Sep 17 00:00:00 2001 From: Myned Date: Sun, 20 Jan 2019 01:35:02 -0500 Subject: [PATCH] Fix(?) reactions causing bot to exit on error --- src/utils/utils.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/utils/utils.py b/src/utils/utils.py index ef157be..04fb8d7 100644 --- a/src/utils/utils.py +++ b/src/utils/utils.py @@ -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) -async def add_reaction(message, reaction, error=err.NotFound): +async def add_reaction(message, reaction, errors=(err.NotFound, err.Forbidden)): sent = False - with suppress(error): + with suppress(errors): await message.add_reaction(reaction) sent = True