I've been recently having issues pop up with my Discord.js bot hosted on repl.it (link is https://replit.com/@anonymouspers27/discordbot#central.js)
The bot worked fine for months. But suddenly, the bot essentially refuses to run. Every time I run npm start, the bot gets stuck on the following code:
(line 31, central.js)
client.once('ready', () => {
console.log('JToH Bot has logged in (loginsuccesful = true)')
});
Now, this section of the code just stopped working. The client is always jut stuck. I've tried basically everything I could find, such as trying to update the code (as it hadn't been updated for a while), but even when I did that, the same problems arised. Nothing has worked so far, and no errors appear in the console, which makes this issue much harder to research on.
I'm positive that the issue must be the code becoming outdated, which I am completely unaware of. I still haven't been able to pinpoint any other spots in the code that causes this problem.