diff --git a/commands/moderation/ban.ts b/commands/moderation/ban.ts index 82b23f8..7abc431 100644 --- a/commands/moderation/ban.ts +++ b/commands/moderation/ban.ts @@ -24,9 +24,9 @@ export default commandModule({ execute: async (ctx, options, message) => { const userToBan = options[1].getMember('usuario', true); const reason = options[1].get('razon', true).value; + userToBan.ban(reason) const sendToMods = ctx.client.guilds.cache.get('928018226330337280')!.channels.cache.get('1004118323258208257') await sendToMods.send({content: `Se ha baneado a ${userToBan}.\nBan efectuado por ${ctx.user} con razón "${reason}."`}) - userToBan.ban(reason) await ctx.reply({content: 'Baneado correctamente!', ephemeral: true}) }, }); \ No newline at end of file diff --git a/commands/moderation/kick.ts b/commands/moderation/kick.ts index bb93491..400c928 100644 --- a/commands/moderation/kick.ts +++ b/commands/moderation/kick.ts @@ -29,9 +29,9 @@ export default commandModule({ const kickEmbed = new EmbedBuilder() .setTitle('Nuevo kick.') .setDescription(`Kick efectuado por <@${ctx.author}>.\nRazón: ${reason}.`); + userToBan.kick(reason) const sendToMods = ctx.client.guilds.cache.get('928018226330337280')!.channels.cache.get('1004118323258208257') await sendToMods.send({content: `Se ha expulsado a ${userToBan}.\nKick efectuado por ${ctx.user} con razón "${reason}."`}) - userToBan.kick(reason) await ctx.reply({content: 'Expulsado correctamente!'}) }, }); \ No newline at end of file diff --git a/commands/moderation/timeoutUser.ts b/commands/moderation/timeoutUser.ts index e55a411..07e4b2f 100644 --- a/commands/moderation/timeoutUser.ts +++ b/commands/moderation/timeoutUser.ts @@ -40,10 +40,9 @@ export default commandModule({ const razon = options[1].getString('razon', true); const minutosToMilisegundos = minutos * 60 * 1000 + usuario.timeout(minutosToMilisegundos, razon).then(() => {ctx.reply({content: `Se ha silenciado a ${usuario} correctamente.`, ephemeral: true})}) const sendToMods = ctx.client.guilds.cache.get('928018226330337280')!.channels.cache.get('1004118323258208257') await sendToMods.send({content: `Se ha silenciado a ${usuario}.\nSlencio efectuado por ${ctx.user} con ${minutos} minutos de duración.\nRazón: ${razon}`}) - - usuario.timeout(minutosToMilisegundos, razon).then(() => {ctx.reply({content: `Se ha silenciado a ${usuario} correctamente.`, ephemeral: true})}) - } + } }, ); \ No newline at end of file