diff options
Diffstat (limited to 'arthur/exts/cloudflare/zones.py')
-rw-r--r-- | arthur/exts/cloudflare/zones.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/arthur/exts/cloudflare/zones.py b/arthur/exts/cloudflare/zones.py index 8a21ad1..6735f50 100644 --- a/arthur/exts/cloudflare/zones.py +++ b/arthur/exts/cloudflare/zones.py @@ -7,6 +7,7 @@ from discord.ext import commands from arthur.apis.cloudflare import zones from arthur.bot import KingArthur from arthur.config import CONFIG +from arthur.log import logger from arthur.utils import generate_error_message @@ -80,4 +81,7 @@ class Zones(commands.Cog): async def setup(bot: KingArthur) -> None: """Add the extension to the bot.""" + if not CONFIG.cloudflare_token: + logger.warning("Not loading Cloudflare Zone cog as cloudflare_token env var is not set.") + return await bot.add_cog(Zones(bot)) |