diff --git a/src/cogs/website_events.py b/src/cogs/website_events.py index c222cc9..40b0a7a 100644 --- a/src/cogs/website_events.py +++ b/src/cogs/website_events.py @@ -68,6 +68,9 @@ class WebsiteEvents(commands.Cog): event (discord.ScheduledEvent): The created event """ + if event.guild_id != self.bot.guild_id: + return + # Convert timezone to Europe/Oslo # We need to set a timezone unit before being able to convert it to another timezone # That's why this line is so fucking weird @@ -107,6 +110,9 @@ class WebsiteEvents(commands.Cog): event (discord.ScheduledEvent): The deleted event """ + if event.guild_id != self.bot.guild_id: + return + mutation = {"mutations": [{"delete": {"id": str(event.id)}}]} response = requests.post(self.api_url, headers=self.auth_header, data=json.dumps(mutation))