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