diff --git a/src/commands/profile/index.ts b/src/commands/profile/index.ts deleted file mode 100644 index dc24a42..0000000 --- a/src/commands/profile/index.ts +++ /dev/null @@ -1,31 +0,0 @@ -// Dependencies -import { SlashCommandBuilder } from "@discordjs/builders"; -import { ChatInputCommandInteraction } from "discord.js"; - -// Modules -import modules from "./modules"; - -// Handlers - -export const moduleData = modules; - -// Function -export const builder = new SlashCommandBuilder() - .setName("profile") - .setDescription("Check a profile.") - .addSubcommand(modules.view.builder); - -// Execute the command -export const execute = async (interaction: ChatInputCommandInteraction) => { - const { options } = interaction; - - switch (options.getSubcommand()) { - case "view": { - await modules.view.execute(interaction); - break; - } - default: { - throw new Error("Could not find module for that command"); - } - } -}; diff --git a/src/commands/profile/modules/index.ts b/src/commands/profile/modules/index.ts deleted file mode 100644 index dc539f8..0000000 --- a/src/commands/profile/modules/index.ts +++ /dev/null @@ -1,3 +0,0 @@ -import view from "./view"; - -export default { view }; diff --git a/src/commands/profile/modules/view/index.ts b/src/commands/profile/modules/view/index.ts deleted file mode 100644 index e0abb27..0000000 --- a/src/commands/profile/modules/view/index.ts +++ /dev/null @@ -1,74 +0,0 @@ -// Dependencies -import { SlashCommandSubcommandBuilder } from "@discordjs/builders"; -import { CommandInteraction } from "discord.js"; -// Configurations -// Models - -// Function -export default { - metadata: { guildOnly: true, ephemeral: false }, - - builder: (command: SlashCommandSubcommandBuilder) => { - return command - .setName("view") - .setDescription("View a profile.") - .addUserOption((option) => - option.setName("target").setDescription("The profile you wish to view") - ); - }, - - execute: async (interaction: CommandInteraction) => { - // const { errorColor, footerText, footerIcon } = await getEmbedConfig( - // interaction.guild - // ); // Destructure - // const { client, options, user, guild } = interaction; - // // Target information - // const target = options?.getUser("target"); - // // Discord User Information - // const discordUser = await client?.users?.fetch( - // `${target ? target?.id : user?.id}` - // ); - // if (guild === null) { - // return logger?.silly(`Guild is null`); - // } - // // User Information - // const userObj = await fetchUser(discordUser, guild); - // const embed = new EmbedBuilder() - // .setAuthor({ - // name: `${discordUser?.username}#${discordUser?.discriminator}`, - // iconURL: discordUser?.displayAvatarURL(), - // }) - // .addFields( - // { - // name: `:dollar: Credits`, - // value: `${userObj?.credits || "Not found"}`, - // inline: true, - // }, - // { - // name: `:squeeze_bottle: Level`, - // value: `${userObj?.level || "Not found"}`, - // inline: true, - // }, - // { - // name: `:squeeze_bottle: Points`, - // value: `${userObj?.points || "Not found"}`, - // inline: true, - // }, - // { - // name: `:loudspeaker: Reputation`, - // value: `${userObj?.reputation || "Not found"}`, - // inline: true, - // }, - // { - // name: `:rainbow_flag: Language`, - // value: `${userObj?.language || "Not found"}`, - // inline: true, - // } - // ) - // .setTimestamp() - // .setColor(errorColor) - // .setFooter({ text: footerText, iconURL: footerIcon }); - // // Return interaction reply - // return interaction?.editReply({ embeds: [embed] }); - }, -};