diff options
Diffstat (limited to 'src/commands/moderation/mute.ts')
-rw-r--r-- | src/commands/moderation/mute.ts | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/commands/moderation/mute.ts b/src/commands/moderation/mute.ts index fba548b..de79b32 100644 --- a/src/commands/moderation/mute.ts +++ b/src/commands/moderation/mute.ts @@ -58,8 +58,13 @@ export default class MuteCommand extends BushCommand { public override async exec( message: BushMessage | BushSlashMessage, - { user, reason, force }: { user: BushUser; reason?: { duration: number; contentWithoutTime: string }; force: boolean } + { + user, + reason, + force + }: { user: BushUser; reason?: { duration: number | null; contentWithoutTime: string }; force: boolean } ): Promise<unknown> { + if (reason?.duration === null) reason.duration = 0; const member = message.guild!.members.cache.get(user.id); if (!member) return await message.util.reply( |