diff options
| author | 2020-08-06 10:53:57 +0200 | |
|---|---|---|
| committer | 2020-08-06 11:17:55 +0200 | |
| commit | fb042c89cd519a41f39eba1559df58fc31a97832 (patch) | |
| tree | 4c6224554754efb0f49e9a4a24bd2a17748d7f4d | |
| parent | Verification: schedule ping task (diff) | |
Verification: remove unverified role on accept
| -rw-r--r-- | bot/cogs/verification.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/bot/cogs/verification.py b/bot/cogs/verification.py index 5586be040..5bc4f81c1 100644 --- a/bot/cogs/verification.py +++ b/bot/cogs/verification.py @@ -422,6 +422,11 @@ class Verification(Cog): """Accept our rules and gain access to the rest of the server.""" log.debug(f"{ctx.author} called !accept. Assigning the 'Developer' role.") await ctx.author.add_roles(discord.Object(constants.Roles.verified), reason="Accepted the rules") + + if constants.Roles.unverified in [role.id for role in ctx.author.roles]: + log.debug(f"Removing Unverified role from: {ctx.author}") + await ctx.author.remove_roles(discord.Object(constants.Roles.unverified)) + try: await ctx.author.send(VERIFIED_MESSAGE) except discord.Forbidden: |