From 9266ce3a1b3e9f20ca01e8bfc75530f1ac21f7cf Mon Sep 17 00:00:00 2001 From: Chris Lovering Date: Sat, 6 May 2023 16:13:14 +0100 Subject: Move unshared contants inside modules --- bot/utils/checks.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'bot/utils') diff --git a/bot/utils/checks.py b/bot/utils/checks.py index 418bb7ad..f1c2b3ce 100644 --- a/bot/utils/checks.py +++ b/bot/utils/checks.py @@ -9,6 +9,7 @@ from discord.ext.commands import ( from bot import constants log = logging.getLogger(__name__) +CODEJAM_CATEGORY_NAME = "Code Jam" class InWhitelistCheckFailure(CheckFailure): @@ -73,7 +74,7 @@ def in_whitelist_check( return True category = getattr(ctx_channel, "category", None) - if category and category.name == constants.CODEJAM_CATEGORY_NAME: + if category and category.name == CODEJAM_CATEGORY_NAME: log.trace(f"{ctx.author} may use the `{ctx.command.name}` command as they are in a codejam team channel.") return True -- cgit v1.2.3