Skip to content

Commit

Permalink
Merge pull request #225 from saiteja-madha/196-timeout-command
Browse files Browse the repository at this point in the history
Fixes Bug #196
  • Loading branch information
Sai Teja Madha authored Nov 7, 2022
2 parents 7bccc64 + 16b725f commit 41dea30
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/commands/moderation/timeout.js
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ module.exports = {
};

async function timeout(issuer, target, ms, reason) {
if (!NaN(Number(ms))) return "Please provide a valid duration. Example: 1d/1h/1m/1s";
if (isNaN(ms)) return "Please provide a valid duration. Example: 1d/1h/1m/1s";
const response = await timeoutTarget(issuer, target, ms, reason);
if (typeof response === "boolean") return `${target.user.tag} is timed out!`;
if (response === "BOT_PERM") return `I do not have permission to timeout ${target.user.tag}`;
Expand Down

0 comments on commit 41dea30

Please sign in to comment.