This commit is contained in:
Dragon Fire
2021-06-20 20:26:24 -04:00
parent adc9d497ee
commit c9848443a3
2 changed files with 3 additions and 4 deletions
+1 -2
View File
@@ -101,8 +101,7 @@ module.exports = class CommandClient extends Client {
}
const throttleAmount = command.throttles.get(msg.author.id);
if (throttleAmount && throttleAmount.usages >= command.throttling.usages) {
const timeout = command._timeouts.get(msg.author.id);
const timeLeft = Math.round((timeout.timeFinish - Date.now()) / 1000);
const timeLeft = Math.round((throttleAmount.timeFinish - Date.now()) / 1000);
await msg.reply(`Please wait ${timeLeft} seconds before using the \`${command.name}\` command again.`);
return;
}