From fb26b7ffcf8c67fc4d3da298b5da705235795ffa Mon Sep 17 00:00:00 2001 From: phxntxm Date: Mon, 1 Jan 2018 18:08:11 -0600 Subject: [PATCH] Add a command to control colours used --- cogs/roles.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cogs/roles.py b/cogs/roles.py index c4c30a9..7472610 100644 --- a/cogs/roles.py +++ b/cogs/roles.py @@ -25,7 +25,7 @@ class Roles: EXAMPLE: !colour red RESULT: A role that matches red (#e74c3c) will be given to you""" - if self.bot.db.load('server_settings', key=ctx.guild.id, pluck="colour_roles_allowed"): + if not self.bot.db.load('server_settings', key=ctx.guild.id, pluck="colour_roles_allowed"): await ctx.send("Colour roles not allowed on this server! " "The command `allowcolours` must be ran to enable them!") return @@ -43,7 +43,7 @@ class Roles: # The colour roles they currently have, we need to remove them if they want a new colour old_roles = [r for r in ctx.author.roles if re.match(r'Bonfire #[0-9a-zA-Z]+', r.name)] if old_roles: - await ctx.author.remove_roles([old_roles]) + await ctx.author.remove_roles(old_roles) # If the role doesn't exist, we need to create it if not role: