aboutsummaryrefslogtreecommitdiff
path: root/src/commands/moderation
diff options
context:
space:
mode:
authorIRONM00N <64110067+IRONM00N@users.noreply.github.com>2021-08-19 12:03:21 -0400
committerIRONM00N <64110067+IRONM00N@users.noreply.github.com>2021-08-19 12:03:21 -0400
commitb29a217f76483e000bd9d75d30250d11a0a88c4d (patch)
tree041b13dc115cf94aff81cda17cf088f2290c2a14 /src/commands/moderation
parent5984cc283ca50099d0e266b994324446316c0013 (diff)
downloadtanzanite-b29a217f76483e000bd9d75d30250d11a0a88c4d.tar.gz
tanzanite-b29a217f76483e000bd9d75d30250d11a0a88c4d.tar.bz2
tanzanite-b29a217f76483e000bd9d75d30250d11a0a88c4d.zip
added steal command, revamped error handling and other stuff
Diffstat (limited to 'src/commands/moderation')
-rw-r--r--src/commands/moderation/ban.ts1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/commands/moderation/ban.ts b/src/commands/moderation/ban.ts
index e32bf18..8a98998 100644
--- a/src/commands/moderation/ban.ts
+++ b/src/commands/moderation/ban.ts
@@ -90,6 +90,7 @@ export default class BanCommand extends BushCommand {
force
}: { user: User; reason?: { duration: number; contentWithoutTime: string }; days?: number; force: boolean }
): Promise<unknown> {
+ if (!message.guild) return message.util.reply(`${util.emojis.error} This command cannot be used in dms.`);
const member = message.guild!.members.cache.get(user.id) as BushGuildMember;
const useForce = force && message.author.isOwner();
const canModerateResponse = util.moderationPermissionCheck(message.member!, member, 'ban', true, useForce);