idk
This commit is contained in:
@@ -56,18 +56,8 @@ module.exports = {
|
||||
|
||||
if (subcommand === 'reload') {
|
||||
|
||||
await interaction.deferReply({ ephemeral: true });
|
||||
|
||||
const { exec } = require('child_process');
|
||||
|
||||
const pm2 = exec('pm2 restart 0', )
|
||||
|
||||
if (pm2.stderr) {
|
||||
await interaction.editReply("An error occurred while reloading the bot.")
|
||||
await interaction.reply({ content: 'In development', ephemeral: true })
|
||||
return
|
||||
}
|
||||
|
||||
await interaction.editReply("Bot reloaded.")
|
||||
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user