Updated all files based on eslintrc

This commit is contained in:
2023-12-31 11:08:49 +01:00
parent da456facef
commit 7d509e1b22
11 changed files with 22 additions and 23 deletions

View File

@@ -12,7 +12,7 @@ export = {
data: new SlashCommandBuilder() data: new SlashCommandBuilder()
.setName("help") .setName("help")
.setDescription("List's all commands usable by a member") .setDescription("List's all commands usable by a member")
.setDMPermission(true), .setDMPermission(false),
async execute(interaction, client) { async execute(interaction, client) {
await interaction.deferReply({ ephemeral: true }) await interaction.deferReply({ ephemeral: true })
@@ -72,9 +72,7 @@ export = {
fields: commandList, fields: commandList,
color: embedColor, color: embedColor,
thumbnail: { thumbnail: {
url: interaction?.guild?.iconURL({ url: interaction.guild!.iconURL({ forceStatic: true, })!,
forceStatic: true,
})!,
}, },
footer: { footer: {
icon_url: footerIcon!, icon_url: footerIcon!,

View File

@@ -17,7 +17,7 @@ export async function updateDiscordRoles(
await interaction.editReply({ await interaction.editReply({
embeds: [ embeds: [
{ {
description: `You do not have permission to use this command.`, description: "You do not have permission to use this command.",
color: embedColor, color: embedColor,
}, },
], ],
@@ -196,7 +196,7 @@ export async function updateDiscordRoles(
await interaction.editReply({ await interaction.editReply({
embeds: [ embeds: [
{ {
description: `Successfully updated all roles.`, description: "Successfully updated all roles.",
color: embedColor, color: embedColor,
}, },
], ],

View File

@@ -4,5 +4,6 @@ export default interface Autocomplete {
name: string name: string
description: string description: string
type: "autocomplete" type: "autocomplete"
execute: (interaction: AutocompleteInteraction) => Promise<void> // eslint-disable-next-line no-unused-vars
execute: (interacion: AutocompleteInteraction) => Promise<void>
} }

View File

@@ -4,5 +4,6 @@ export default interface Button {
name: string name: string
description: string description: string
type: "button" type: "button"
// eslint-disable-next-line no-unused-vars
execute: (interaction: ButtonInteraction) => Promise<void> execute: (interaction: ButtonInteraction) => Promise<void>
} }

View File

@@ -12,8 +12,6 @@ export default interface Command {
"addSubcommand" | "addSubcommandGroup" | "addIntegerOption" "addSubcommand" | "addSubcommandGroup" | "addIntegerOption"
> >
subcommands?: boolean subcommands?: boolean
execute: ( // eslint-disable-next-line no-unused-vars
interaction: ChatInputCommandInteraction, execute: ( interaction: ChatInputCommandInteraction, client: Client,) => Promise<void>
client: Client,
) => Promise<void>
} }

View File

@@ -9,5 +9,6 @@ export default interface ContextMenu {
type: "contextmenu" type: "contextmenu"
dev?: boolean dev?: boolean
data: ContextMenuCommandBuilder data: ContextMenuCommandBuilder
// eslint-disable-next-line no-unused-vars
execute: (interaction: ContextMenuCommandInteraction) => Promise<void> execute: (interaction: ContextMenuCommandInteraction) => Promise<void>
} }

View File

@@ -5,5 +5,6 @@ export default interface Event {
description: string description: string
type: "event" type: "event"
event: keyof ClientEvents event: keyof ClientEvents
// eslint-disable-next-line no-unused-vars
execute(...args: any[]): void execute(...args: any[]): void
} }

View File

@@ -4,5 +4,6 @@ export default interface Modal {
name: string name: string
description: string description: string
type: "modal" type: "modal"
// eslint-disable-next-line no-unused-vars
execute: (interaction: ModalSubmitInteraction) => Promise<void> execute: (interaction: ModalSubmitInteraction) => Promise<void>
} }

View File

@@ -8,8 +8,6 @@ const client = new Client()
const redis = new Redis(env.prod.redisURI!) const redis = new Redis(env.prod.redisURI!)
class Bot { class Bot {
constructor() {}
async start() { async start() {
init() init()
client.start() client.start()