From 4bc064cc456422e864df0ba42ef64417c6e56e70 Mon Sep 17 00:00:00 2001 From: Konstantin Dyachenko Date: Wed, 6 Mar 2024 21:30:15 +0300 Subject: [PATCH] Fix bug --- index.ts | 7 ------- 1 file changed, 7 deletions(-) diff --git a/index.ts b/index.ts index 35a1f08..1e102bd 100644 --- a/index.ts +++ b/index.ts @@ -51,13 +51,6 @@ const startBot = async (deep, botToken) => { console.log(`Logged in as ${discordClient.user.tag}!`); }); - process.on('unhandledRejection', async (event) => { - const eventString = JSON.stringify(event, null, 2); - console.error('Unhandled rejection:', eventString); - await discordClient.destroy(); - // throw new Error(`Unhandled rejection error: ${eventString}`); - }); - discordClient.on('exit', (event) => { const eventString = JSON.stringify(event, null, 2); console.log(`Discord bot is exited:`, event);