So I was coding a discord bot using discord.js recently i am facing a issue that when ever i run my bot on mine local machine all the commands works but when i commit and push the code to github and through with the help of buddy.works my code gets edited on my vps. but from few days and commands are not working even though vps is fine and pm2 restart command is also working. Please tell me any fixes to fix this problem.
Regards
Open two terminal (command prompt) windows. Connect to your VPS inside both windows. In one window run pm2 logs, in the other run pm2 restart [process-name].
In the window with pm2 logs, it'll start logging out the errors that come. (you may need to run one of the commands first). This may be due to a missing package, or something like that.
If you end up finding the error and are unsure how to fix it, feel free to edit your post to accommodate it.