aboutsummaryrefslogtreecommitdiff
path: root/src/commands/utilities/steal.ts
diff options
context:
space:
mode:
authorIRONM00N <64110067+IRONM00N@users.noreply.github.com>2022-09-05 17:36:42 -0400
committerIRONM00N <64110067+IRONM00N@users.noreply.github.com>2022-09-05 17:36:42 -0400
commit048f99752550c6e03d1990a03cad78f3ac7d73aa (patch)
treec238ac29b1b526e86bcbc4989036df981c860187 /src/commands/utilities/steal.ts
parent6f8a4d13a490eda7a195d14833c83810f7b5a789 (diff)
downloadtanzanite-048f99752550c6e03d1990a03cad78f3ac7d73aa.tar.gz
tanzanite-048f99752550c6e03d1990a03cad78f3ac7d73aa.tar.bz2
tanzanite-048f99752550c6e03d1990a03cad78f3ac7d73aa.zip
revamp command permissions, fix permission exploit for some command when used in forum channels, use enums more
Diffstat (limited to 'src/commands/utilities/steal.ts')
-rw-r--r--src/commands/utilities/steal.ts18
1 files changed, 4 insertions, 14 deletions
diff --git a/src/commands/utilities/steal.ts b/src/commands/utilities/steal.ts
index 7f70830..a208920 100644
--- a/src/commands/utilities/steal.ts
+++ b/src/commands/utilities/steal.ts
@@ -1,17 +1,7 @@
-import {
- Arg,
- BotCommand,
- clientSendAndPermCheck,
- emojis,
- format,
- OptArgType,
- regex,
- type CommandMessage,
- type SlashMessage
-} from '#lib';
+import { Arg, BotCommand, emojis, format, OptArgType, regex, type CommandMessage, type SlashMessage } from '#lib';
import assert from 'assert/strict';
import { type ArgumentGeneratorReturn, type ArgumentType, type ArgumentTypeCaster } from 'discord-akairo';
-import { ApplicationCommandOptionType, Attachment, PermissionFlagsBits } from 'discord.js';
+import { ApplicationCommandOptionType, Attachment } from 'discord.js';
import _ from 'lodash';
import { Stream } from 'stream';
import { URL } from 'url';
@@ -46,8 +36,8 @@ export default class StealCommand extends BotCommand {
],
slash: true,
channel: 'guild',
- clientPermissions: (m) => clientSendAndPermCheck(m, [PermissionFlagsBits.ManageEmojisAndStickers]),
- userPermissions: [PermissionFlagsBits.ManageEmojisAndStickers]
+ clientPermissions: ['ManageEmojisAndStickers'],
+ userPermissions: ['ManageEmojisAndStickers']
});
}