diff options
| author | 2020-08-08 11:04:24 +0200 | |
|---|---|---|
| committer | 2020-08-08 11:04:24 +0200 | |
| commit | f3c16f77d812be50c2b7bed4c046cd67f3b9b761 (patch) | |
| tree | bd8593ea5c2bf5e67b1da3c218fd3eac40f63de1 | |
| parent | Verification: improve `is_verified` check (diff) | |
Verification: only take reactions from core devs
Co-authored-by: MarkKoz <[email protected]>
| -rw-r--r-- | bot/cogs/verification.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/bot/cogs/verification.py b/bot/cogs/verification.py index d4064cff7..da2f81e2d 100644 --- a/bot/cogs/verification.py +++ b/bot/cogs/verification.py @@ -196,12 +196,14 @@ class Verification(Cog): for option in options: await confirmation_msg.add_reaction(option) + core_dev_ids = [member.id for member in pydis.get_role(constants.Roles.core_developers).members] + def check(reaction: discord.Reaction, user: discord.User) -> bool: """Check whether `reaction` is a valid reaction to `confirmation_msg`.""" return ( reaction.message.id == confirmation_msg.id # Reacted to `confirmation_msg` and str(reaction.emoji) in options # With one of `options` - and not user.bot # By a human + and user.id in core_dev_ids # By a core developer ) timeout = 60 * 5 # Seconds, i.e. 5 minutes |