From c2fbeef6e5ed9acf17ed24ecb1cce45e6c22d8ea Mon Sep 17 00:00:00 2001 From: Corey Johnson Date: Thu, 19 Jun 2025 17:07:27 -0700 Subject: [PATCH] Update index.ts --- packages/spike/src/discord/index.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/spike/src/discord/index.ts b/packages/spike/src/discord/index.ts index 1dec46c..3e1aa39 100644 --- a/packages/spike/src/discord/index.ts +++ b/packages/spike/src/discord/index.ts @@ -18,14 +18,14 @@ await client.login(process.env.DISCORD_TOKEN) listenForEvents(client) -process.on("unhandledRejection", (error) => { +process.on("unhandledRejection", async (error) => { console.error("💥 Unhandled promise rejection:", error) - logCrash(error) + await logCrash(error) }) -process.on("uncaughtException", (error) => { +process.on("uncaughtException", async (error) => { console.error("💥 Uncaught exception:", error) - logCrash(error) + await logCrash(error) }) runCronJobs(client)