From 8c43abc2d9ff377a31c5edc373c17cfb177219b7 Mon Sep 17 00:00:00 2001 From: snipe <72265661+notsniped@users.noreply.github.com> Date: Mon, 2 Jun 2025 19:21:11 +0530 Subject: [PATCH] Make bot shutdown command (for developers) --- main.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/main.py b/main.py index 66b3c87..2d74456 100644 --- a/main.py +++ b/main.py @@ -555,6 +555,18 @@ async def reload(ctx: ApplicationContext, cog: str): ) ) +# Core Developer Commands +@client.slash_command( + name="shutdown", + description="Shut down the bot as a developer." +) +async def shutdown(ctx: ApplicationContext): + """Shut down the bot as a developer.""" + if ctx.author.id != 738290097170153472: + return await ctx.respond("You can't use this command!", ephemeral=True) + ctx.respond(":sleeping: Acknowledged. Isobot will now shut down.") + raise SystemExit + # Settings commands config = client.create_group("settings", "Commands used to change bot settings.")