⚰️ remove unused variables (JS-0356)
This commit is contained in:
parent
1c56ff9bcb
commit
9a11af4c1e
14 changed files with 10 additions and 25 deletions
|
@ -3,7 +3,6 @@ import { CommandInteraction, ButtonInteraction, Message } from "discord.js";
|
|||
|
||||
import logger from "../../logger";
|
||||
|
||||
import getEmbedConfig from "../../helpers/getEmbedConfig";
|
||||
import timeoutSchema from "../../models/timeout";
|
||||
import addSeconds from "../../helpers/addSeconds";
|
||||
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
import { CommandInteraction } from "discord.js";
|
||||
import { ButtonInteraction } from "discord.js";
|
||||
import logger from "../../../logger";
|
||||
|
||||
export const metadata = { guildOnly: false, ephemeral: false };
|
||||
|
||||
export const execute = async (interaction: CommandInteraction) => {
|
||||
logger.debug("primary button clicked!");
|
||||
export const execute = async (interaction: ButtonInteraction) => {
|
||||
logger.debug(interaction.customId, "primary button clicked!");
|
||||
};
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
import { CommandInteraction } from "discord.js";
|
||||
import { SlashCommandBuilder } from "@discordjs/builders";
|
||||
import logger from "../../../logger";
|
||||
|
||||
import modules from "../../commands/counters/modules";
|
||||
|
||||
|
|
|
@ -4,7 +4,6 @@ import { CommandInteraction } from "discord.js";
|
|||
|
||||
// Groups
|
||||
import modules from "../../commands/manage/modules";
|
||||
import logger from "../../../logger";
|
||||
|
||||
export const moduleData = modules;
|
||||
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
import { CommandInteraction } from "discord.js";
|
||||
import { SlashCommandSubcommandGroupBuilder } from "@discordjs/builders";
|
||||
import logger from "../../../../../logger";
|
||||
|
||||
import modules from "./modules";
|
||||
|
||||
|
|
|
@ -6,7 +6,6 @@ import { CommandInteraction } from "discord.js";
|
|||
import modules from "./modules";
|
||||
|
||||
// Handlers
|
||||
import logger from "../../../logger";
|
||||
|
||||
export const moduleData = modules;
|
||||
|
||||
|
|
|
@ -37,8 +37,9 @@ export default {
|
|||
execute: async (interaction: CommandInteraction) => {
|
||||
const { options, user, guild } = interaction;
|
||||
|
||||
const { errorColor, successColor, footerText, footerIcon } =
|
||||
await getEmbedConfig(guild); // Destructure
|
||||
const { successColor, footerText, footerIcon } = await getEmbedConfig(
|
||||
guild
|
||||
); // Destructure
|
||||
|
||||
const optionTarget = options?.getUser("target");
|
||||
const optionType = options?.getString("type");
|
||||
|
|
|
@ -16,7 +16,6 @@ import pluralize from "../../../../../helpers/pluralize";
|
|||
import apiSchema from "../../../../../models/api";
|
||||
import fetchUser from "../../../../../helpers/fetchUser";
|
||||
import { SlashCommandSubcommandBuilder } from "@discordjs/builders";
|
||||
import { message } from "../../../../../helpers/cooldown/index";
|
||||
|
||||
export default {
|
||||
metadata: { guildOnly: true, ephemeral: true },
|
||||
|
|
|
@ -1,14 +1,9 @@
|
|||
// Dependencies
|
||||
import {
|
||||
CommandInteraction,
|
||||
MessageActionRow,
|
||||
MessageButton,
|
||||
} from "discord.js";
|
||||
import { CommandInteraction } from "discord.js";
|
||||
|
||||
// Configurations
|
||||
import getEmbedConfig from "../../../../../helpers/getEmbedConfig";
|
||||
|
||||
import { hosterName, hosterUrl } from "../../../../../config/other";
|
||||
import { SlashCommandSubcommandBuilder } from "@discordjs/builders";
|
||||
|
||||
// Function
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import logger from "../../../logger";
|
||||
import { GuildMember, MessageEmbed, TextChannel } from "discord.js";
|
||||
import { GuildMember, MessageEmbed } from "discord.js";
|
||||
|
||||
import guildSchema from "../../../models/guild";
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import logger from "../../../logger";
|
||||
import { GuildMember, MessageEmbed, TextChannel } from "discord.js";
|
||||
import { GuildMember, MessageEmbed } from "discord.js";
|
||||
|
||||
import guildSchema from "../../../models/guild";
|
||||
|
||||
|
|
|
@ -3,8 +3,6 @@ import { Interaction } from "discord.js";
|
|||
import button from "./button";
|
||||
import command from "./command";
|
||||
|
||||
import logger from "../../../../logger";
|
||||
|
||||
export const execute = async (interaction: Interaction) => {
|
||||
await button(interaction);
|
||||
await command(interaction);
|
||||
|
|
|
@ -14,9 +14,6 @@ export default {
|
|||
if (author.bot) return;
|
||||
if (channel?.type !== "GUILD_TEXT") return;
|
||||
|
||||
const { id: guildId } = guild;
|
||||
const { id: userId } = author;
|
||||
|
||||
const guildData = await fetchGuild(guild);
|
||||
const userData = await fetchUser(author, guild);
|
||||
|
||||
|
|
|
@ -10,5 +10,5 @@ export const options: IEventOptions = {
|
|||
};
|
||||
|
||||
export const execute = async (client: Client) => {
|
||||
logger.warn("Discord's API client is rate-limited!");
|
||||
logger.warn(`Discord's API client (${client?.user?.tag}) is rate-limited!`);
|
||||
};
|
||||
|
|
Loading…
Add table
Reference in a new issue