diff options
author | IRONM00N <64110067+IRONM00N@users.noreply.github.com> | 2021-11-07 10:21:23 -0500 |
---|---|---|
committer | IRONM00N <64110067+IRONM00N@users.noreply.github.com> | 2021-11-07 10:21:23 -0500 |
commit | 4e97002a5702f8128e8c0763bd7b762ccd5806da (patch) | |
tree | 4f9227318a4afb2c289fa1c442cbc26333cbd00d /src | |
parent | 9b8689d8ebf9afba3dcbd985d5cc59370e8250dd (diff) | |
download | tanzanite-4e97002a5702f8128e8c0763bd7b762ccd5806da.tar.gz tanzanite-4e97002a5702f8128e8c0763bd7b762ccd5806da.tar.bz2 tanzanite-4e97002a5702f8128e8c0763bd7b762ccd5806da.zip |
remove duplicate names
Diffstat (limited to 'src')
-rw-r--r-- | src/lib/utils/BushConstants.ts | 16 | ||||
-rw-r--r-- | src/listeners/commands/messageBlocked.ts | 4 |
2 files changed, 10 insertions, 10 deletions
diff --git a/src/lib/utils/BushConstants.ts b/src/lib/utils/BushConstants.ts index c719f72..cc7673e 100644 --- a/src/lib/utils/BushConstants.ts +++ b/src/lib/utils/BushConstants.ts @@ -329,19 +329,19 @@ export class BushConstants { }; public static get ArgumentMatches() { - return ArgumentMatches + return ArgumentMatchesEnum }; public static get ArgumentTypes() { - return BushArgumentTypes + return BushArgumentTypesEnum }; public static get BlockedReasons() { - return BushBlockedReasons + return BushBlockedReasonsEnum }; public static get CommandHandlerEvents() { - return BushCommandHandlerEvents + return BushCommandHandlerEventsEnum }; public static moulberryBushRoleMap = [ @@ -416,7 +416,7 @@ export enum BushEmojis { check = '<:check:878320135297961995>' } -export enum ArgumentMatches { +export enum ArgumentMatchesEnum { PHRASE = "phrase", FLAG = "flag", OPTION = "option", @@ -428,7 +428,7 @@ export enum ArgumentMatches { NONE = "none" } -export enum BushArgumentTypes { +export enum BushArgumentTypesEnum { STRING = "string", LOWERCASE = "lowercase", UPPERCASE = "uppercase", @@ -493,7 +493,7 @@ export enum BushArgumentTypes { GLOBAL_USER = 'globalUser', } -export enum BushBlockedReasons { +export enum BushBlockedReasonsEnum { CLIENT = 'client', BOT = 'bot', OWNER = 'owner', @@ -513,7 +513,7 @@ export enum BushBlockedReasons { RESTRICTED_CHANNEL = 'restrictedChannel' } -export enum BushCommandHandlerEvents { +export enum BushCommandHandlerEventsEnum { COMMAND_BLOCKED = "commandBlocked", COMMAND_BREAKOUT = "commandBreakout", COMMAND_CANCELLED = "commandCancelled", diff --git a/src/listeners/commands/messageBlocked.ts b/src/listeners/commands/messageBlocked.ts index d567f8c..6a0eaab 100644 --- a/src/listeners/commands/messageBlocked.ts +++ b/src/listeners/commands/messageBlocked.ts @@ -1,4 +1,4 @@ -import { BushListener, type BushCommandHandlerEvents } from '#lib'; +import { BushListener, type BushBlockedReasonsEnum, type BushCommandHandlerEvents } from '#lib'; export default class MessageBlockedListener extends BushListener { public constructor() { @@ -10,7 +10,7 @@ export default class MessageBlockedListener extends BushListener { public override async exec(...[message, reason]: BushCommandHandlerEvents['messageBlocked']) { const reasons = client.consts.BlockedReasons; - if ([reasons.CLIENT, reasons.BOT].includes(reason)) return; + if ([reasons.CLIENT, reasons.BOT].includes(reason as BushBlockedReasonsEnum)) return; // return await CommandBlockedListener.handleBlocked(message as Message, null, reason); return void client.console.verbose(`messageBlocked`, `<<${message.author.tag}>>'s message was blocked because ${reason}`); } |