Fix a bunch of linter errors
diff --git a/src/commands/nucleus/_meta.ts b/src/commands/nucleus/_meta.ts
index df978ba..a79a596 100644
--- a/src/commands/nucleus/_meta.ts
+++ b/src/commands/nucleus/_meta.ts
@@ -1,4 +1,4 @@
const name = "nucleus";
const description = "Commands relating to Nucleus itself";
-export { name, description };
\ No newline at end of file
+export { name, description };
diff --git a/src/commands/nucleus/guide.ts b/src/commands/nucleus/guide.ts
index 3141f9f..b9df446 100644
--- a/src/commands/nucleus/guide.ts
+++ b/src/commands/nucleus/guide.ts
@@ -6,7 +6,6 @@
.setName("guide")
.setDescription("Shows the welcome guide for the bot");
-
const callback = async (interaction) => {
guide(interaction.guild, interaction);
};
diff --git a/src/commands/nucleus/invite.ts b/src/commands/nucleus/invite.ts
index ebc3c34..8ae8c1a 100644
--- a/src/commands/nucleus/invite.ts
+++ b/src/commands/nucleus/invite.ts
@@ -1,24 +1,38 @@
-import { CommandInteraction, MessageActionRow, MessageButton } from "discord.js";
+import {
+ CommandInteraction,
+ MessageActionRow,
+ MessageButton
+} from "discord.js";
import { SlashCommandSubcommandBuilder } from "@discordjs/builders";
import EmojiEmbed from "../../utils/generateEmojiEmbed.js";
import client from "../../utils/client.js";
const command = (builder: SlashCommandSubcommandBuilder) =>
- builder
- .setName("invite")
- .setDescription("Invites Nucleus to your server");
+ builder.setName("invite").setDescription("Invites Nucleus to your server");
const callback = async (interaction: CommandInteraction): Promise<void> => {
- interaction.reply({embeds: [new EmojiEmbed()
- .setTitle("Invite")
- .setDescription("You can invite Nucleus to your server by clicking the button below")
- .setEmoji("NUCLEUS.LOGO")
- .setStatus("Danger")
- ], components: [new MessageActionRow().addComponents([new MessageButton()
- .setLabel("Invite")
- .setStyle("LINK")
- .setURL(`https://discord.com/api/oauth2/authorize?client_id=${client.user.id}&permissions=295157886134&scope=bot%20applications.commands`)
- ])], ephemeral: true});
+ interaction.reply({
+ embeds: [
+ new EmojiEmbed()
+ .setTitle("Invite")
+ .setDescription(
+ "You can invite Nucleus to your server by clicking the button below"
+ )
+ .setEmoji("NUCLEUS.LOGO")
+ .setStatus("Danger")
+ ],
+ components: [
+ new MessageActionRow().addComponents([
+ new MessageButton()
+ .setLabel("Invite")
+ .setStyle("LINK")
+ .setURL(
+ `https://discord.com/api/oauth2/authorize?client_id=${client.user.id}&permissions=295157886134&scope=bot%20applications.commands`
+ )
+ ])
+ ],
+ ephemeral: true
+ });
};
const check = () => {
@@ -27,4 +41,4 @@
export { command };
export { callback };
-export { check };
\ No newline at end of file
+export { check };
diff --git a/src/commands/nucleus/ping.ts b/src/commands/nucleus/ping.ts
index 91e8363..105cda5 100644
--- a/src/commands/nucleus/ping.ts
+++ b/src/commands/nucleus/ping.ts
@@ -5,26 +5,29 @@
import client from "../../utils/client.js";
const command = (builder: SlashCommandSubcommandBuilder) =>
- builder
- .setName("ping")
- .setDescription("Gets the bot's ping time");
+ builder.setName("ping").setDescription("Gets the bot's ping time");
const callback = async (interaction: CommandInteraction): Promise<void> => {
// WEBSOCKET | Nucleus -> Discord
// EDITING | Nucleus -> discord -> nucleus | edit time / 2
const initial = new Date().getTime();
- await interaction.reply({embeds: LoadingEmbed, ephemeral: true});
+ await interaction.reply({ embeds: LoadingEmbed, ephemeral: true });
const ping = new Date().getTime() - initial;
- interaction.editReply({embeds: [new EmojiEmbed()
- .setTitle("Ping")
- .setDescription(
- `**Ping:** \`${ping}ms\`\n` +
- `**To Discord:** \`${client.ws.ping}ms\`\n` +
- `**From Expected:** \`±${Math.abs((ping / 2) - client.ws.ping)}ms\``
- )
- .setEmoji("CHANNEL.SLOWMODE.OFF")
- .setStatus("Danger")
- ]});
+ interaction.editReply({
+ embeds: [
+ new EmojiEmbed()
+ .setTitle("Ping")
+ .setDescription(
+ `**Ping:** \`${ping}ms\`\n` +
+ `**To Discord:** \`${client.ws.ping}ms\`\n` +
+ `**From Expected:** \`±${Math.abs(
+ ping / 2 - client.ws.ping
+ )}ms\``
+ )
+ .setEmoji("CHANNEL.SLOWMODE.OFF")
+ .setStatus("Danger")
+ ]
+ });
};
const check = () => {
@@ -33,4 +36,4 @@
export { command };
export { callback };
-export { check };
\ No newline at end of file
+export { check };
diff --git a/src/commands/nucleus/premium.ts b/src/commands/nucleus/premium.ts
index 9ad2c16..83ba327 100644
--- a/src/commands/nucleus/premium.ts
+++ b/src/commands/nucleus/premium.ts
@@ -8,17 +8,21 @@
.setDescription("Information about Nucleus Premium");
const callback = async (interaction: CommandInteraction): Promise<void> => {
- interaction.reply({embeds: [new EmojiEmbed()
- .setTitle("Premium")
- .setDescription(
- "*Nucleus Premium is currently not available.*\n\n" +
- "Premium allows your server to get access to extra features, for a fixed price per month.\nThis includes:\n" +
- "- Attachment logs - Stores attachments so they can be viewed after a message is deleted.\n" +
- "- Ticket Transcripts - Gives a link to view the history of a ticket after it has been closed.\n"
- )
- .setEmoji("NUCLEUS.LOGO")
- .setStatus("Danger")
- ], ephemeral: true});
+ interaction.reply({
+ embeds: [
+ new EmojiEmbed()
+ .setTitle("Premium")
+ .setDescription(
+ "*Nucleus Premium is currently not available.*\n\n" +
+ "Premium allows your server to get access to extra features, for a fixed price per month.\nThis includes:\n" +
+ "- Attachment logs - Stores attachments so they can be viewed after a message is deleted.\n" +
+ "- Ticket Transcripts - Gives a link to view the history of a ticket after it has been closed.\n"
+ )
+ .setEmoji("NUCLEUS.LOGO")
+ .setStatus("Danger")
+ ],
+ ephemeral: true
+ });
};
const check = () => {
@@ -27,4 +31,4 @@
export { command };
export { callback };
-export { check };
\ No newline at end of file
+export { check };
diff --git a/src/commands/nucleus/stats.ts b/src/commands/nucleus/stats.ts
index 2558997..68eeaa9 100644
--- a/src/commands/nucleus/stats.ts
+++ b/src/commands/nucleus/stats.ts
@@ -4,22 +4,21 @@
import client from "../../utils/client.js";
const command = (builder: SlashCommandSubcommandBuilder) =>
- builder
- .setName("stats")
- .setDescription("Gets the bot's stats");
+ builder.setName("stats").setDescription("Gets the bot's stats");
const callback = async (interaction: CommandInteraction): Promise<void> => {
interaction.reply({
- embeds: [new EmojiEmbed()
- .setTitle("Stats")
- .setDescription(
- `**Servers:** ${client.guilds.cache.size}\n` +
- `**Ping:** \`${client.ws.ping*2}ms\``
- )
- .setStatus("Success")
- .setEmoji("GUILD.GRAPHS")
-
- ], ephemeral: true
+ embeds: [
+ new EmojiEmbed()
+ .setTitle("Stats")
+ .setDescription(
+ `**Servers:** ${client.guilds.cache.size}\n` +
+ `**Ping:** \`${client.ws.ping * 2}ms\``
+ )
+ .setStatus("Success")
+ .setEmoji("GUILD.GRAPHS")
+ ],
+ ephemeral: true
});
};
@@ -29,4 +28,4 @@
export { command };
export { callback };
-export { check };
\ No newline at end of file
+export { check };
diff --git a/src/commands/nucleus/suggest.ts b/src/commands/nucleus/suggest.ts
index a6657d8..0f40501 100644
--- a/src/commands/nucleus/suggest.ts
+++ b/src/commands/nucleus/suggest.ts
@@ -9,7 +9,12 @@
builder
.setName("suggest")
.setDescription("Sends a suggestion to the developers")
- .addStringOption(option => option.setName("suggestion").setDescription("The suggestion to send").setRequired(true));
+ .addStringOption((option) =>
+ option
+ .setName("suggestion")
+ .setDescription("The suggestion to send")
+ .setRequired(true)
+ );
const callback = async (interaction: CommandInteraction): Promise<void> => {
const { renderUser } = client.logger;
@@ -17,42 +22,63 @@
const confirmation = await new confirmationMessage(interaction)
.setEmoji("ICONS.OPP.ADD")
.setTitle("Suggest")
- .setDescription(`**Suggestion:**\n> ${suggestion}\n`
- + "Your username and ID will also be sent with your suggestion.\n\nAre you sure you want to send this suggestion?")
+ .setDescription(
+ `**Suggestion:**\n> ${suggestion}\n` +
+ "Your username and ID will also be sent with your suggestion.\n\nAre you sure you want to send this suggestion?"
+ )
.setColor("Danger")
.setInverted(true)
.send();
if (confirmation.cancelled) return;
if (confirmation.success) {
- await (client.channels.cache.get("955161206459600976") as Discord.TextChannel).send({
+ await (
+ client.channels.cache.get(
+ "955161206459600976"
+ ) as Discord.TextChannel
+ ).send({
embeds: [
new EmojiEmbed()
.setTitle("Suggestion")
- .setDescription(`**From:** ${renderUser(interaction.member.user)}\n**Suggestion:**\n> ${suggestion}`)
+ .setDescription(
+ `**From:** ${renderUser(
+ interaction.member.user
+ )}\n**Suggestion:**\n> ${suggestion}`
+ )
.setStatus("Danger")
.setEmoji("NUCLEUS.LOGO")
]
});
- await interaction.editReply({embeds: [new EmojiEmbed()
- .setEmoji("ICONS.ADD")
- .setTitle("Suggest")
- .setDescription("Your suggestion was sent successfully")
- .setStatus("Success")
- ], components: []});
+ await interaction.editReply({
+ embeds: [
+ new EmojiEmbed()
+ .setEmoji("ICONS.ADD")
+ .setTitle("Suggest")
+ .setDescription("Your suggestion was sent successfully")
+ .setStatus("Success")
+ ],
+ components: []
+ });
} else {
- await interaction.editReply({embeds: [new EmojiEmbed()
- .setEmoji("ICONS.OPP.ADD")
- .setTitle("Suggest")
- .setDescription("No changes were made")
- .setStatus("Danger")
- ], components: []});
+ await interaction.editReply({
+ embeds: [
+ new EmojiEmbed()
+ .setEmoji("ICONS.OPP.ADD")
+ .setTitle("Suggest")
+ .setDescription("No changes were made")
+ .setStatus("Danger")
+ ],
+ components: []
+ });
}
};
-const check = (_interaction: CommandInteraction, _defaultCheck: WrappedCheck) => {
+const check = (
+ _interaction: CommandInteraction,
+ _defaultCheck: WrappedCheck
+) => {
return true;
};
export { command };
export { callback };
-export { check };
\ No newline at end of file
+export { check };