Catch no permissions to remove reaction
This commit is contained in:
parent
0fc3ccc518
commit
1fd5362177
|
@ -1,3 +1,5 @@
|
||||||
|
import discord
|
||||||
|
|
||||||
from discord.ext import commands
|
from discord.ext import commands
|
||||||
|
|
||||||
import utils
|
import utils
|
||||||
|
@ -33,7 +35,10 @@ class Poll:
|
||||||
continue
|
continue
|
||||||
users = await r.users().flatten()
|
users = await r.users().flatten()
|
||||||
if member.id in [x.id for x in users]:
|
if member.id in [x.id for x in users]:
|
||||||
await self.message.remove_reaction(r, member)
|
try:
|
||||||
|
await self.message.remove_reaction(r, member)
|
||||||
|
except discord.Forbidden:
|
||||||
|
return
|
||||||
|
|
||||||
|
|
||||||
class Polls(commands.Cog):
|
class Polls(commands.Cog):
|
||||||
|
|
Loading…
Reference in a new issue