Prevent user from timing out a bot

This commit is contained in:
Ethan Lane 2023-06-19 17:40:06 +01:00
parent 4f2c186244
commit ffe182e504
2 changed files with 42 additions and 0 deletions

View file

@ -49,6 +49,11 @@ export default class Timeout extends Command {
return;
}
if (targetUser.user.bot) {
await interaction.reply('Cannot timeout bots.');
return;
}
// General Variables
const targetMember = targetUser.member as GuildMember;
const reason = reasonInput && reasonInput.value ? reasonInput.value.toString() : null;