dosent let go more than 120 sec

This commit is contained in:
Loic Bersier 2018-12-28 00:50:41 +01:00
parent 66a2dc21a0
commit ecb27a72e3

View file

@ -21,6 +21,8 @@ module.exports = class CustomResponseCommand extends Command {
} }
async run(message, { slowmodeNumber }) { async run(message, { slowmodeNumber }) {
if (slowmodeNumber < 120)
message.say("Slowmode can only be set to 120 seconds or lower!");
message.channel.setRateLimitPerUser(slowmodeNumber); message.channel.setRateLimitPerUser(slowmodeNumber);
message.say(`Slowmode have been set to ${slowmodeNumber} seconds`); message.say(`Slowmode have been set to ${slowmodeNumber} seconds`);
} }