From ef92902932e4105eecd1eb5eec6c0521f73d39a7 Mon Sep 17 00:00:00 2001 From: imcompiling Date: Wed, 19 Mar 2025 11:39:08 -0400 Subject: [PATCH] Add utils to define guild ids that will use this bot. --- off_cooldown_bot/cogs/commands/birthday.py | 3 ++- off_cooldown_bot/utils.py | 3 +++ 2 files changed, 5 insertions(+), 1 deletion(-) create mode 100644 off_cooldown_bot/utils.py diff --git a/off_cooldown_bot/cogs/commands/birthday.py b/off_cooldown_bot/cogs/commands/birthday.py index 5a5c731..2845260 100644 --- a/off_cooldown_bot/cogs/commands/birthday.py +++ b/off_cooldown_bot/cogs/commands/birthday.py @@ -10,12 +10,13 @@ from sqlmodel import Session, col, select from off_cooldown_bot.app import birthday_list from off_cooldown_bot.database.db import engine from off_cooldown_bot.database.models import UserBirthday +from off_cooldown_bot.utils import GUILDS class BirthdayCog(commands.Cog, name="Birthday Commands"): """Class holds birthday commands.""" - @nextcord.slash_command(guild_ids=[1000247361639030804, 822199658306076672]) + @nextcord.slash_command(guild_ids=GUILDS) async def birthday(self, interaction: nextcord.Interaction) -> None: """Parent slash command for birthday. Never called.""" diff --git a/off_cooldown_bot/utils.py b/off_cooldown_bot/utils.py new file mode 100644 index 0000000..ed9b32e --- /dev/null +++ b/off_cooldown_bot/utils.py @@ -0,0 +1,3 @@ +"""File contains functions and variables used widely.""" + +GUILDS = [1000247361639030804, 822199658306076672]