diff --git a/commands/Moderation/clear.js b/commands/Moderation/clear.js index b4fab619..738955b3 100644 --- a/commands/Moderation/clear.js +++ b/commands/Moderation/clear.js @@ -35,7 +35,7 @@ class Clear extends Command { }); } - let amount = args[0]; + const amount = args[0]; if (!amount || isNaN(amount) || parseInt(amount) < 1) return message.error("moderation/clear:MISSING_AMOUNT"); await message.delete(); @@ -49,7 +49,6 @@ class Clear extends Command { if (messages.length > amount) messages.length = parseInt(amount, 10); messages = messages.filter((m) => !m.pinned); - amount++; message.channel.bulkDelete(messages, true); @@ -57,12 +56,12 @@ class Clear extends Command { if (user) { toDelete = await message.success("moderation/clear:CLEARED_MEMBER", { - amount: `${--amount} ${message.getNoun(--amount, message.translate("misc:NOUNS:MESSAGES:1"), message.translate("misc:NOUNS:MESSAGES:2"), message.translate("misc:NOUNS:MESSAGES:5"))}`, + amount: `${amount} ${message.getNoun(amount, message.translate("misc:NOUNS:MESSAGES:1"), message.translate("misc:NOUNS:MESSAGES:2"), message.translate("misc:NOUNS:MESSAGES:5"))}`, username: user.tag }); } else { toDelete = await message.success("moderation/clear:CLEARED", { - amount: `${--amount} ${message.getNoun(--amount, message.translate("misc:NOUNS:MESSAGES:1"), message.translate("misc:NOUNS:MESSAGES:2"), message.translate("misc:NOUNS:MESSAGES:5"))}` + amount: `${amount} ${message.getNoun(amount, message.translate("misc:NOUNS:MESSAGES:1"), message.translate("misc:NOUNS:MESSAGES:2"), message.translate("misc:NOUNS:MESSAGES:5"))}` }); } diff --git a/commands/Moderation/clearsanctions.js b/commands/Moderation/clearwarns.js similarity index 100% rename from commands/Moderation/clearsanctions.js rename to commands/Moderation/clearwarns.js diff --git a/languages/en-US/moderation/clearsanctions.json b/languages/en-US/moderation/clearwarns.json similarity index 64% rename from languages/en-US/moderation/clearsanctions.json rename to languages/en-US/moderation/clearwarns.json index 820e6a92..233cc644 100644 --- a/languages/en-US/moderation/clearsanctions.json +++ b/languages/en-US/moderation/clearwarns.json @@ -1,7 +1,7 @@ { "DESCRIPTION": "Clear a member sanctions!", - "USAGE": "{{prefix}}clear-sanctions [@member]", - "EXAMPLES": "{{prefix}}clear-sanctions @Jonny_Bro#4226", + "USAGE": "{{prefix}}clearwarns [@member]", + "EXAMPLES": "{{prefix}}clearwarns @Jonny_Bro#4226", "MISSING_MEMBER": "Please mention the member you wish to remove the sanctions from!", "SUCCESS": "**{{username}}**'s sanctions were deleted!" } \ No newline at end of file