diff options
Diffstat (limited to 'src/lib')
-rw-r--r-- | src/lib/extensions/discord-akairo/BushClient.ts | 4 | ||||
-rw-r--r-- | src/lib/extensions/discord-akairo/BushClientUtil.ts | 2 | ||||
-rw-r--r-- | src/lib/models/ActivePunishment.ts | 2 | ||||
-rw-r--r-- | src/lib/models/ModLog.ts | 1 | ||||
-rw-r--r-- | src/lib/models/Stat.ts | 1 | ||||
-rw-r--r-- | src/lib/models/StickyRole.ts | 1 | ||||
-rw-r--r-- | src/lib/models/__helpers.ts | 1 | ||||
-rw-r--r-- | src/lib/utils/BushConstants.ts | 12 |
8 files changed, 9 insertions, 15 deletions
diff --git a/src/lib/extensions/discord-akairo/BushClient.ts b/src/lib/extensions/discord-akairo/BushClient.ts index c2d8970..39eff3b 100644 --- a/src/lib/extensions/discord-akairo/BushClient.ts +++ b/src/lib/extensions/discord-akairo/BushClient.ts @@ -30,7 +30,7 @@ import { } from 'discord.js'; //@ts-ignore: no typings import eventsIntercept from 'events-intercept'; -import path, { dirname } from 'path'; +import path from 'path'; import readline from 'readline'; import type { Sequelize as SequelizeType } from 'sequelize'; import { fileURLToPath } from 'url'; @@ -114,7 +114,7 @@ const rl = readline.createInterface({ type If<T extends boolean, A, B = null> = T extends true ? A : T extends false ? B : A | B; -const __dirname = dirname(fileURLToPath(import.meta.url)); +const __dirname = path.dirname(fileURLToPath(import.meta.url)); export class BushClient<Ready extends boolean = boolean> extends AkairoClient<Ready> { public declare channels: BushChannelManager; diff --git a/src/lib/extensions/discord-akairo/BushClientUtil.ts b/src/lib/extensions/discord-akairo/BushClientUtil.ts index 594c9af..f619b4b 100644 --- a/src/lib/extensions/discord-akairo/BushClientUtil.ts +++ b/src/lib/extensions/discord-akairo/BushClientUtil.ts @@ -36,12 +36,12 @@ import { type UserResolvable } from 'discord.js'; import got from 'got'; -import humanizeDuration from 'humanize-duration'; import _ from 'lodash'; import moment from 'moment'; import { inspect, promisify } from 'util'; import CommandErrorListener from '../../../listeners/commands/commandError.js'; import { Format } from '../../common/Format.js'; +const { default: humanizeDuration } = await import ('humanize-duration') export class BushClientUtil extends ClientUtil { /** diff --git a/src/lib/models/ActivePunishment.ts b/src/lib/models/ActivePunishment.ts index 23dd33b..ec1b500 100644 --- a/src/lib/models/ActivePunishment.ts +++ b/src/lib/models/ActivePunishment.ts @@ -2,10 +2,8 @@ import { type Snowflake } from 'discord.js'; import { nanoid } from 'nanoid'; import { type Sequelize } from 'sequelize'; import { BaseModel } from './BaseModel.js'; - const { DataTypes } = (await import('sequelize')).default - export enum ActivePunishmentType { BAN = 'BAN', MUTE = 'MUTE', diff --git a/src/lib/models/ModLog.ts b/src/lib/models/ModLog.ts index 757ee66..bb1be8c 100644 --- a/src/lib/models/ModLog.ts +++ b/src/lib/models/ModLog.ts @@ -3,7 +3,6 @@ import { nanoid } from 'nanoid'; import { type Sequelize } from 'sequelize'; import { BaseModel } from './BaseModel.js'; import { jsonBoolean } from './__helpers.js'; - const { DataTypes } = (await import('sequelize')).default export enum ModLogType { diff --git a/src/lib/models/Stat.ts b/src/lib/models/Stat.ts index c5f02b8..31111df 100644 --- a/src/lib/models/Stat.ts +++ b/src/lib/models/Stat.ts @@ -1,7 +1,6 @@ import { type Sequelize } from 'sequelize'; import { BaseModel } from './BaseModel.js'; import { jsonBigint } from './__helpers.js'; - const { DataTypes } = (await import('sequelize')).default type Environment = 'production' | 'development' | 'beta'; diff --git a/src/lib/models/StickyRole.ts b/src/lib/models/StickyRole.ts index a6f604d..63c9726 100644 --- a/src/lib/models/StickyRole.ts +++ b/src/lib/models/StickyRole.ts @@ -2,7 +2,6 @@ import { type Snowflake } from 'discord.js'; import { type Sequelize } from 'sequelize'; import { BaseModel } from './BaseModel.js'; import { jsonArray } from './__helpers.js'; - const { DataTypes } = (await import('sequelize')).default export interface StickyRoleModel { diff --git a/src/lib/models/__helpers.ts b/src/lib/models/__helpers.ts index 3b7f4a4..8c98d5b 100644 --- a/src/lib/models/__helpers.ts +++ b/src/lib/models/__helpers.ts @@ -2,7 +2,6 @@ import { type Model } from 'sequelize'; const { DataTypes } = (await import('sequelize')).default - export function jsonParseGet(this: Model, key: string): any { return JSON.parse(this.getDataValue(key)); } diff --git a/src/lib/utils/BushConstants.ts b/src/lib/utils/BushConstants.ts index cc7673e..c48f7d7 100644 --- a/src/lib/utils/BushConstants.ts +++ b/src/lib/utils/BushConstants.ts @@ -199,12 +199,12 @@ export class BushConstants { BOOST_TIER_1: '<:boostitle:853363736679940127>', BOOST_TIER_2: '<:boostitle:853363752728789075>', BOOST_TIER_3: '<:boostitle:853363769132056627>', - TEXT: '<:text:853375537791893524>', - NEWS: '<:announcements:853375553531674644>', - VOICE: '<:voice:853375566735212584>', - STAGE: '<:stage:853375583521210468>', - STORE: '<:store:853375601175691266>', - CATEGORY: '<:category:853375615260819476>', + GUILD_TEXT: '<:text:853375537791893524>', + GUILD_NEWS: '<:announcements:853375553531674644>', + GUILD_VOICE: '<:voice:853375566735212584>', + GUILD_STAGE_VOICE: '<:stage:853375583521210468>', + GUILD_STORE: '<:store:853375601175691266>', + GUILD_CATEGORY: '<:category:853375615260819476>', THREAD: '<:thread:865033845753249813>' }, |