Updated subcommands to use default export
This commit is contained in:
@@ -1,9 +1,9 @@
|
||||
import { SlashCommandBuilder } from "discord.js"
|
||||
import { color, devMessage } from "../../config/options.json"
|
||||
import { Command } from "../interfaces"
|
||||
import guildMember = require("./guild/member")
|
||||
import guildInfo = require("./guild/info")
|
||||
import guildTop = require("./guild/top")
|
||||
import guildMember from "./guild/member"
|
||||
import guildInfo from "./guild/info"
|
||||
import guildTop from "./guild/top"
|
||||
|
||||
export = {
|
||||
name: "guild",
|
||||
|
||||
@@ -9,7 +9,7 @@ import { color, devMessage } from "../../../config/options.json"
|
||||
import { ChatInputCommandInteraction } from "discord.js"
|
||||
import { GuildData } from "../../interfaces/Guild"
|
||||
|
||||
async function guildInfo(
|
||||
export default async function guildInfo(
|
||||
interaction: ChatInputCommandInteraction,
|
||||
): Promise<void> {
|
||||
await interaction.deferReply()
|
||||
@@ -241,6 +241,4 @@ async function guildInfo(
|
||||
},
|
||||
],
|
||||
})
|
||||
}
|
||||
|
||||
export = guildInfo
|
||||
}
|
||||
@@ -2,7 +2,7 @@ import { getUUID, getPlayer, getGuild, getHeadURL } from "../../utils/Hypixel"
|
||||
import { color, devMessage } from "../../../config/options.json"
|
||||
import { ChatInputCommandInteraction } from "discord.js"
|
||||
|
||||
async function guildMember(
|
||||
export default async function guildMember(
|
||||
interaction: ChatInputCommandInteraction,
|
||||
): Promise<void> {
|
||||
await interaction.deferReply()
|
||||
@@ -211,6 +211,4 @@ async function guildMember(
|
||||
},
|
||||
],
|
||||
})
|
||||
}
|
||||
|
||||
export = guildMember
|
||||
}
|
||||
@@ -5,7 +5,7 @@ import { GuildData } from "../../interfaces/Guild"
|
||||
import Illegitimate from "../../utils/Illegitimate"
|
||||
const redis = Illegitimate.redis
|
||||
|
||||
async function guildTop(
|
||||
export default async function guildTop(
|
||||
interaction: ChatInputCommandInteraction,
|
||||
): Promise<void> {
|
||||
await interaction.deferReply()
|
||||
@@ -291,6 +291,4 @@ async function guildTop(
|
||||
},
|
||||
],
|
||||
})
|
||||
}
|
||||
|
||||
export = guildTop
|
||||
}
|
||||
@@ -1,9 +1,9 @@
|
||||
import { SlashCommandBuilder, PermissionFlagsBits } from "discord.js"
|
||||
import { color, devMessage } from "../../config/options.json"
|
||||
import { Command } from "../interfaces"
|
||||
import { help } from "./staff/help"
|
||||
import { beast } from "./staff/beast"
|
||||
import { updateDiscordRoles } from "./staff/updatediscordroles"
|
||||
import help from "./staff/help"
|
||||
import beast from "./staff/beast"
|
||||
import updateDiscordRoles from "./staff/updatediscordroles"
|
||||
|
||||
export = {
|
||||
name: "staff",
|
||||
|
||||
@@ -19,7 +19,7 @@ import {
|
||||
} from "../../utils/Hypixel"
|
||||
import { ChatInputCommandInteraction } from "discord.js"
|
||||
|
||||
export async function beast(
|
||||
export default async function beast(
|
||||
interaction: ChatInputCommandInteraction,
|
||||
): Promise<void> {
|
||||
await interaction.deferReply()
|
||||
|
||||
@@ -2,7 +2,7 @@ import { ChatInputCommandInteraction } from "discord.js"
|
||||
import { color, devMessage } from "../../../config/options.json"
|
||||
import { ExtendedClient as Client } from "../../utils/Client"
|
||||
|
||||
export async function help(
|
||||
export default async function help(
|
||||
interaction: ChatInputCommandInteraction,
|
||||
client: Client,
|
||||
): Promise<void> {
|
||||
|
||||
@@ -6,7 +6,7 @@ import env from "../../utils/Env"
|
||||
import { getGuild } from "../../utils/Hypixel"
|
||||
import { GuildData } from "../../interfaces"
|
||||
|
||||
export async function updateDiscordRoles(
|
||||
export default async function updateDiscordRoles(
|
||||
interaction: ChatInputCommandInteraction,
|
||||
): Promise<void> {
|
||||
const discordMember = interaction.member as GuildMember
|
||||
|
||||
Reference in New Issue
Block a user