Update index.ts
This commit is contained in:
parent
14f7f008f3
commit
2292b3fa62
|
|
@ -1,7 +1,7 @@
|
|||
import { Client, GatewayIntentBits, Partials } from "discord.js"
|
||||
import { listenForEvents } from "@/discord/events"
|
||||
import { runCronJobs } from "@/discord/cron"
|
||||
import { clearCrashLog, logCrash } from "@/discord/crash"
|
||||
import { alertAboutCrashLog, logCrash } from "@/discord/crash"
|
||||
|
||||
const client = new Client({
|
||||
intents: [
|
||||
|
|
@ -17,7 +17,6 @@ const client = new Client({
|
|||
await client.login(process.env.DISCORD_TOKEN)
|
||||
|
||||
listenForEvents(client)
|
||||
alertAboutCrashLog(client)
|
||||
|
||||
process.on("unhandledRejection", (error) => {
|
||||
console.error("💥 Unhandled promise rejection:", error)
|
||||
|
|
@ -30,4 +29,5 @@ process.on("uncaughtException", (error) => {
|
|||
})
|
||||
|
||||
runCronJobs(client)
|
||||
await alertAboutCrashLog(client)
|
||||
// startAuthServer() this is handy if you make a new bot
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user