diff options
author | IRONM00N <64110067+IRONM00N@users.noreply.github.com> | 2021-12-29 16:15:06 -0500 |
---|---|---|
committer | IRONM00N <64110067+IRONM00N@users.noreply.github.com> | 2021-12-29 16:15:06 -0500 |
commit | 08d7e6eb125c5ff6846c3a92491de79d291b8e12 (patch) | |
tree | 4abdaeee3ad258ef8fa0d7b517ea49d262d18b0b /src/commands/moderation/warn.ts | |
parent | f9cf43fc47be2d497d92d728ea892246df96d736 (diff) | |
download | tanzanite-08d7e6eb125c5ff6846c3a92491de79d291b8e12.tar.gz tanzanite-08d7e6eb125c5ff6846c3a92491de79d291b8e12.tar.bz2 tanzanite-08d7e6eb125c5ff6846c3a92491de79d291b8e12.zip |
misc improvements & typings changes
Diffstat (limited to 'src/commands/moderation/warn.ts')
-rw-r--r-- | src/commands/moderation/warn.ts | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/commands/moderation/warn.ts b/src/commands/moderation/warn.ts index 95e409d..5093c9b 100644 --- a/src/commands/moderation/warn.ts +++ b/src/commands/moderation/warn.ts @@ -1,12 +1,12 @@ import { AllowedMentions, - ArgType, BushCommand, Moderation, - OptionalArgType, + type ArgType, type BushGuildMember, type BushMessage, - type BushSlashMessage + type BushSlashMessage, + type OptionalArgType } from '#lib'; export default class WarnCommand extends BushCommand { @@ -55,7 +55,7 @@ export default class WarnCommand extends BushCommand { public override async exec( message: BushMessage | BushSlashMessage, - { user, reason, force }: { user: ArgType<'user'>; reason: OptionalArgType<'string'>; force?: boolean } + { user, reason, force = false }: { user: ArgType<'user'>; reason: OptionalArgType<'string'>; force?: boolean } ) { const member = message.guild!.members.cache.get(user.id) as BushGuildMember; if (!member) return message.util.reply(`${util.emojis.error} I cannot warn users that are not in the server.`); |