Skip to content

Commit

Permalink
chore: Refactor error handling and launch method in index.js
Browse files Browse the repository at this point in the history
  • Loading branch information
gnehs committed Jul 19, 2024
1 parent 39acb07 commit cda25ad
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ bot.use(
require("./components/subscribe/index")
);

bot.launch().catch((err) => {
console.log(err);
bot.launch();

// catch error
process.on("unhandledRejection", (error) => {
console.error(error);
});

0 comments on commit cda25ad

Please sign in to comment.