From 8c48473ef3df9c171386ca6a96c26ac0113c6c97 Mon Sep 17 00:00:00 2001 From: Anthony Berg Date: Sat, 6 Jan 2024 02:31:31 +0000 Subject: [PATCH] refactor(arabot): ran prettier --- src/commands/coordinators/private.ts | 5 ++++- src/commands/mod/diversity.ts | 5 ++++- src/commands/mod/restriction/restrictTools.ts | 5 ++++- src/commands/outreach/outreach.ts | 5 ++++- src/interaction-handlers/nonVeganAccess.ts | 5 ++++- src/interaction-handlers/welcome.ts | 5 ++++- src/listeners/ban/ban.ts | 5 ++++- src/listeners/ban/banJoin.ts | 5 ++++- src/listeners/ban/unban.ts | 5 ++++- src/listeners/botAppreciation.ts | 5 ++++- src/listeners/commandDenied.ts | 5 ++++- src/listeners/counting.ts | 5 ++++- src/listeners/dbLeaveServer.ts | 5 ++++- src/listeners/deniedPermission.ts | 5 ++++- src/listeners/eventTypes.ts | 5 ++++- src/listeners/nonVeganAccess.ts | 5 ++++- src/listeners/ready.ts | 5 ++++- src/listeners/rolesJoinServer.ts | 5 ++++- src/listeners/suggestions.ts | 5 ++++- src/listeners/vcMute.ts | 5 ++++- src/listeners/verification/messageCounter.ts | 5 ++++- src/listeners/verification/start.ts | 5 ++++- src/listeners/verification/welcome.ts | 5 ++++- src/listeners/xp.ts | 5 ++++- src/scheduled-tasks/tempBan.ts | 2 +- 25 files changed, 97 insertions(+), 25 deletions(-) diff --git a/src/commands/coordinators/private.ts b/src/commands/coordinators/private.ts index 5f216e5..6e15728 100644 --- a/src/commands/coordinators/private.ts +++ b/src/commands/coordinators/private.ts @@ -31,7 +31,10 @@ import { import IDs from '#utils/ids'; export class PrivateCommand extends Subcommand { - public constructor(context: Subcommand.LoaderContext, options: Subcommand.Options) { + public constructor( + context: Subcommand.LoaderContext, + options: Subcommand.Options, + ) { super(context, { ...options, name: 'private', diff --git a/src/commands/mod/diversity.ts b/src/commands/mod/diversity.ts index 1d5ad90..bd3af96 100644 --- a/src/commands/mod/diversity.ts +++ b/src/commands/mod/diversity.ts @@ -31,7 +31,10 @@ import type { TextChannel, Snowflake } from 'discord.js'; import IDs from '#utils/ids'; export class DiversityCommand extends Subcommand { - public constructor(context: Subcommand.LoaderContext, options: Subcommand.Options) { + public constructor( + context: Subcommand.LoaderContext, + options: Subcommand.Options, + ) { super(context, { ...options, name: 'diversity', diff --git a/src/commands/mod/restriction/restrictTools.ts b/src/commands/mod/restriction/restrictTools.ts index 8991910..2b16605 100644 --- a/src/commands/mod/restriction/restrictTools.ts +++ b/src/commands/mod/restriction/restrictTools.ts @@ -24,7 +24,10 @@ import { CategoryChannel, ChannelType } from 'discord.js'; import IDs from '#utils/ids'; export class RestrictToolsCommand extends Subcommand { - public constructor(context: Subcommand.LoaderContext, options: Subcommand.Options) { + public constructor( + context: Subcommand.LoaderContext, + options: Subcommand.Options, + ) { super(context, { ...options, name: 'restricttools', diff --git a/src/commands/outreach/outreach.ts b/src/commands/outreach/outreach.ts index 83decc5..58424e7 100644 --- a/src/commands/outreach/outreach.ts +++ b/src/commands/outreach/outreach.ts @@ -38,7 +38,10 @@ import IDs from '#utils/ids'; import { EmbedBuilder } from 'discord.js'; export class OutreachCommand extends Subcommand { - public constructor(context: Subcommand.LoaderContext, options: Subcommand.Options) { + public constructor( + context: Subcommand.LoaderContext, + options: Subcommand.Options, + ) { super(context, { ...options, name: 'outreach', diff --git a/src/interaction-handlers/nonVeganAccess.ts b/src/interaction-handlers/nonVeganAccess.ts index f79f505..6a79ee4 100644 --- a/src/interaction-handlers/nonVeganAccess.ts +++ b/src/interaction-handlers/nonVeganAccess.ts @@ -25,7 +25,10 @@ import type { ButtonInteraction, GuildMember } from 'discord.js'; import IDs from '#utils/ids'; export class NonVeganAccessButtonHandler extends InteractionHandler { - public constructor(ctx: InteractionHandler.LoaderContext, options: InteractionHandler.Options) { + public constructor( + ctx: InteractionHandler.LoaderContext, + options: InteractionHandler.Options, + ) { super(ctx, { ...options, interactionHandlerType: InteractionHandlerTypes.Button, diff --git a/src/interaction-handlers/welcome.ts b/src/interaction-handlers/welcome.ts index 160d557..fed4a93 100644 --- a/src/interaction-handlers/welcome.ts +++ b/src/interaction-handlers/welcome.ts @@ -25,7 +25,10 @@ import type { ButtonInteraction, GuildMember, TextChannel } from 'discord.js'; import IDs from '#utils/ids'; export class WelcomeButtonHandler extends InteractionHandler { - public constructor(ctx: InteractionHandler.LoaderContext, options: InteractionHandler.Options) { + public constructor( + ctx: InteractionHandler.LoaderContext, + options: InteractionHandler.Options, + ) { super(ctx, { ...options, interactionHandlerType: InteractionHandlerTypes.Button, diff --git a/src/listeners/ban/ban.ts b/src/listeners/ban/ban.ts index f12008b..50293ed 100644 --- a/src/listeners/ban/ban.ts +++ b/src/listeners/ban/ban.ts @@ -25,7 +25,10 @@ import IDs from '#utils/ids'; import { addEmptyUser, addExistingUser } from '#utils/database/dbExistingUser'; export class BanListener extends Listener { - public constructor(context: Listener.LoaderContext, options: Listener.Options) { + public constructor( + context: Listener.LoaderContext, + options: Listener.Options, + ) { super(context, { ...options, event: 'guildBanAdd', diff --git a/src/listeners/ban/banJoin.ts b/src/listeners/ban/banJoin.ts index 9d155e3..7a8afa7 100644 --- a/src/listeners/ban/banJoin.ts +++ b/src/listeners/ban/banJoin.ts @@ -23,7 +23,10 @@ import { checkBan, getBanReason } from '#utils/database/ban'; import { checkTempBan } from '#utils/database/tempBan'; export class BanJoinListener extends Listener { - public constructor(context: Listener.LoaderContext, options: Listener.Options) { + public constructor( + context: Listener.LoaderContext, + options: Listener.Options, + ) { super(context, { ...options, event: 'guildMemberAdd', diff --git a/src/listeners/ban/unban.ts b/src/listeners/ban/unban.ts index 787e32d..c237b70 100644 --- a/src/listeners/ban/unban.ts +++ b/src/listeners/ban/unban.ts @@ -25,7 +25,10 @@ import IDs from '#utils/ids'; import { addEmptyUser, addExistingUser } from '#utils/database/dbExistingUser'; export class UnbanListener extends Listener { - public constructor(context: Listener.LoaderContext, options: Listener.Options) { + public constructor( + context: Listener.LoaderContext, + options: Listener.Options, + ) { super(context, { ...options, event: 'guildBanRemove', diff --git a/src/listeners/botAppreciation.ts b/src/listeners/botAppreciation.ts index 021e3e3..c7eed20 100644 --- a/src/listeners/botAppreciation.ts +++ b/src/listeners/botAppreciation.ts @@ -21,7 +21,10 @@ import { Listener } from '@sapphire/framework'; import type { Message } from 'discord.js'; export class BotAppreciationListener extends Listener { - public constructor(context: Listener.LoaderContext, options: Listener.Options) { + public constructor( + context: Listener.LoaderContext, + options: Listener.Options, + ) { super(context, { ...options, event: 'messageCreate', diff --git a/src/listeners/commandDenied.ts b/src/listeners/commandDenied.ts index ee2b8d5..2b82364 100644 --- a/src/listeners/commandDenied.ts +++ b/src/listeners/commandDenied.ts @@ -24,7 +24,10 @@ import type { import { Listener } from '@sapphire/framework'; export class OldCommandDeniedListener extends Listener { - public constructor(context: Listener.LoaderContext, options: Listener.Options) { + public constructor( + context: Listener.LoaderContext, + options: Listener.Options, + ) { super(context, { ...options, event: 'messageCommandDenied', diff --git a/src/listeners/counting.ts b/src/listeners/counting.ts index b692d66..2d8feb3 100644 --- a/src/listeners/counting.ts +++ b/src/listeners/counting.ts @@ -25,7 +25,10 @@ import { getLastCount, addCount } from '#utils/database/counting'; import IDs from '#utils/ids'; export class XpListener extends Listener { - public constructor(context: Listener.LoaderContext, options: Listener.Options) { + public constructor( + context: Listener.LoaderContext, + options: Listener.Options, + ) { super(context, { ...options, event: 'messageCreate', diff --git a/src/listeners/dbLeaveServer.ts b/src/listeners/dbLeaveServer.ts index 0c20b59..ddf28eb 100644 --- a/src/listeners/dbLeaveServer.ts +++ b/src/listeners/dbLeaveServer.ts @@ -27,7 +27,10 @@ import { } from '#utils/database/dbExistingUser'; export class DbLeaveServerListener extends Listener { - public constructor(context: Listener.LoaderContext, options: Listener.Options) { + public constructor( + context: Listener.LoaderContext, + options: Listener.Options, + ) { super(context, { ...options, event: 'guildMemberRemove', diff --git a/src/listeners/deniedPermission.ts b/src/listeners/deniedPermission.ts index b002cac..6d3c446 100644 --- a/src/listeners/deniedPermission.ts +++ b/src/listeners/deniedPermission.ts @@ -24,7 +24,10 @@ import type { import { Listener } from '@sapphire/framework'; export class CommandDeniedListener extends Listener { - public constructor(context: Listener.LoaderContext, options: Listener.Options) { + public constructor( + context: Listener.LoaderContext, + options: Listener.Options, + ) { super(context, { ...options, event: 'chatInputCommandDenied', diff --git a/src/listeners/eventTypes.ts b/src/listeners/eventTypes.ts index a1b1ea5..8d832f7 100644 --- a/src/listeners/eventTypes.ts +++ b/src/listeners/eventTypes.ts @@ -24,7 +24,10 @@ import { Listener } from '@sapphire/framework'; import { setupTypes } from '#utils/database/outreach'; export class EventTypesReadyListener extends Listener { - public constructor(context: Listener.LoaderContext, options: Listener.Options) { + public constructor( + context: Listener.LoaderContext, + options: Listener.Options, + ) { super(context, { ...options, once: true, diff --git a/src/listeners/nonVeganAccess.ts b/src/listeners/nonVeganAccess.ts index 5198f6e..545bd89 100644 --- a/src/listeners/nonVeganAccess.ts +++ b/src/listeners/nonVeganAccess.ts @@ -24,7 +24,10 @@ import type { Client, TextChannel } from 'discord.js'; import IDs from '#utils/ids'; export class NonVeganAccessReady extends Listener { - public constructor(context: Listener.LoaderContext, options: Listener.Options) { + public constructor( + context: Listener.LoaderContext, + options: Listener.Options, + ) { super(context, { ...options, once: true, diff --git a/src/listeners/ready.ts b/src/listeners/ready.ts index d07e993..c6721be 100644 --- a/src/listeners/ready.ts +++ b/src/listeners/ready.ts @@ -24,7 +24,10 @@ import { Listener } from '@sapphire/framework'; import type { Client } from 'discord.js'; export class ReadyListener extends Listener { - public constructor(context: Listener.LoaderContext, options: Listener.Options) { + public constructor( + context: Listener.LoaderContext, + options: Listener.Options, + ) { super(context, { ...options, once: true, diff --git a/src/listeners/rolesJoinServer.ts b/src/listeners/rolesJoinServer.ts index 5ce3aba..a07968e 100644 --- a/src/listeners/rolesJoinServer.ts +++ b/src/listeners/rolesJoinServer.ts @@ -33,7 +33,10 @@ import { blockedRoles, blockedRolesAfterRestricted } from '#utils/blockedRoles'; import IDs from '#utils/ids'; export class RolesJoinServerListener extends Listener { - public constructor(context: Listener.LoaderContext, options: Listener.Options) { + public constructor( + context: Listener.LoaderContext, + options: Listener.Options, + ) { super(context, { ...options, event: 'guildMemberAdd', diff --git a/src/listeners/suggestions.ts b/src/listeners/suggestions.ts index b101bed..0bc0fcd 100644 --- a/src/listeners/suggestions.ts +++ b/src/listeners/suggestions.ts @@ -23,7 +23,10 @@ import type { Message } from 'discord.js'; import IDs from '#utils/ids'; export class Suggestions extends Listener { - public constructor(context: Listener.LoaderContext, options: Listener.Options) { + public constructor( + context: Listener.LoaderContext, + options: Listener.Options, + ) { super(context, { ...options, event: 'messageCreate', diff --git a/src/listeners/vcMute.ts b/src/listeners/vcMute.ts index 3c5d553..75c882a 100644 --- a/src/listeners/vcMute.ts +++ b/src/listeners/vcMute.ts @@ -22,7 +22,10 @@ import type { VoiceState } from 'discord.js'; import { checkActive, removeMute } from '#utils/database/vcMute'; export class VCMuteListener extends Listener { - public constructor(context: Listener.LoaderContext, options: Listener.Options) { + public constructor( + context: Listener.LoaderContext, + options: Listener.Options, + ) { super(context, { ...options, event: 'voiceStateUpdate', diff --git a/src/listeners/verification/messageCounter.ts b/src/listeners/verification/messageCounter.ts index aa60116..8266099 100644 --- a/src/listeners/verification/messageCounter.ts +++ b/src/listeners/verification/messageCounter.ts @@ -22,7 +22,10 @@ import type { Message } from 'discord.js'; import IDs from '#utils/ids'; export class VerificationMessageCounter extends Listener { - public constructor(context: Listener.LoaderContext, options: Listener.Options) { + public constructor( + context: Listener.LoaderContext, + options: Listener.Options, + ) { super(context, { ...options, event: 'messageCreate', diff --git a/src/listeners/verification/start.ts b/src/listeners/verification/start.ts index 10c5afc..99e6dc8 100644 --- a/src/listeners/verification/start.ts +++ b/src/listeners/verification/start.ts @@ -29,7 +29,10 @@ import { createVerificationVoice } from '#utils/verification'; import IDs from '#utils/ids'; export class VerificationReady extends Listener { - public constructor(context: Listener.LoaderContext, options: Listener.Options) { + public constructor( + context: Listener.LoaderContext, + options: Listener.Options, + ) { super(context, { ...options, once: true, diff --git a/src/listeners/verification/welcome.ts b/src/listeners/verification/welcome.ts index e8f759b..9da68ff 100644 --- a/src/listeners/verification/welcome.ts +++ b/src/listeners/verification/welcome.ts @@ -24,7 +24,10 @@ import type { Client, TextChannel } from 'discord.js'; import IDs from '#utils/ids'; export class VerificationReady extends Listener { - public constructor(context: Listener.LoaderContext, options: Listener.Options) { + public constructor( + context: Listener.LoaderContext, + options: Listener.Options, + ) { super(context, { ...options, once: true, diff --git a/src/listeners/xp.ts b/src/listeners/xp.ts index 68f4181..32f3fe0 100644 --- a/src/listeners/xp.ts +++ b/src/listeners/xp.ts @@ -23,7 +23,10 @@ import { addXp, checkCanAddXp } from '#utils/database/xp'; import { randint } from '#utils/maths'; export class XpListener extends Listener { - public constructor(context: Listener.LoaderContext, options: Listener.Options) { + public constructor( + context: Listener.LoaderContext, + options: Listener.Options, + ) { super(context, { ...options, event: 'messageCreate', diff --git a/src/scheduled-tasks/tempBan.ts b/src/scheduled-tasks/tempBan.ts index 9f9ad80..49f34fa 100644 --- a/src/scheduled-tasks/tempBan.ts +++ b/src/scheduled-tasks/tempBan.ts @@ -102,6 +102,6 @@ export class TempBan extends ScheduledTask { declare module '@sapphire/plugin-scheduled-tasks' { interface ScheduledTasks { - tempBan: { userId: string; guildId: string } + tempBan: { userId: string; guildId: string }; } }