diff --git a/bots/discord/src/commands/moderation/cure.ts b/bots/discord/src/commands/moderation/cure.ts index e1895a6..60d9a0b 100644 --- a/bots/discord/src/commands/moderation/cure.ts +++ b/bots/discord/src/commands/moderation/cure.ts @@ -3,6 +3,7 @@ import { SlashCommandBuilder } from 'discord.js' import type { Command } from '..' import { config } from '$/context' +import { createSuccessEmbed } from '$/utils/discord/embeds' import { cureNickname } from '$/utils/discord/moderation' export default { @@ -19,8 +20,12 @@ export default { global: false, async execute(_, interaction) { - const user = interaction.options.getUser('user', true) + const user = interaction.options.getUser('member', true) const member = await interaction.guild!.members.fetch(user.id) await cureNickname(member) + await interaction.reply({ + embeds: [createSuccessEmbed(null, `Cured nickname for ${member.toString()}`)], + ephemeral: true, + }) }, } satisfies Command diff --git a/bots/discord/src/commands/moderation/mute.ts b/bots/discord/src/commands/moderation/mute.ts index 8cd8bbc..fa6ea26 100644 --- a/bots/discord/src/commands/moderation/mute.ts +++ b/bots/discord/src/commands/moderation/mute.ts @@ -45,7 +45,7 @@ export default { 'The provided member is not in the server or does not exist.', ) - if (member.manageable) + if (!member.manageable) throw new CommandError(CommandErrorType.Generic, 'This user cannot be managed by the bot.') if (moderator.roles.highest.comparePositionTo(member.roles.highest) <= 0 && !userIsOwner) diff --git a/bots/discord/src/commands/moderation/role-preset.ts b/bots/discord/src/commands/moderation/role-preset.ts index 959b664..f8eac4b 100644 --- a/bots/discord/src/commands/moderation/role-preset.ts +++ b/bots/discord/src/commands/moderation/role-preset.ts @@ -50,7 +50,7 @@ export default { 'The provided member is not in the server or does not exist.', ) - if (member.manageable) + if (!member.manageable) throw new CommandError(CommandErrorType.Generic, 'This user cannot be managed by the bot.') if (action === 'apply') {