feat: implement graceful shutdown handling
This commit is contained in:
@@ -11,4 +11,8 @@ await AuroraClient.deployCommands();
|
||||
if (!env.DISCORD_BOT_TOKEN) {
|
||||
throw new Error("❌ DISCORD_BOT_TOKEN is not set in environment variables.");
|
||||
}
|
||||
AuroraClient.login(env.DISCORD_BOT_TOKEN);
|
||||
AuroraClient.login(env.DISCORD_BOT_TOKEN);
|
||||
|
||||
// Handle graceful shutdown
|
||||
process.on("SIGINT", () => AuroraClient.shutdown());
|
||||
process.on("SIGTERM", () => AuroraClient.shutdown());
|
||||
Reference in New Issue
Block a user