Removed all instances of client.interaction with import client from utils
diff --git a/src/commands/nucleus/invite.ts b/src/commands/nucleus/invite.ts
index 44934e1..8b25820 100644
--- a/src/commands/nucleus/invite.ts
+++ b/src/commands/nucleus/invite.ts
@@ -2,6 +2,7 @@
import { SlashCommandSubcommandBuilder } from "@discordjs/builders";
import { WrappedCheck } from "jshaiku";
import generateEmojiEmbed from "../../utils/generateEmojiEmbed.js";
+import client from "../../utils/client.js"
const command = (builder: SlashCommandSubcommandBuilder) =>
builder
@@ -17,7 +18,7 @@
], components: [new MessageActionRow().addComponents([new MessageButton()
.setLabel("Invite")
.setStyle("LINK")
- .setURL(`https://discord.com/api/oauth2/authorize?client_id=${interaction.client.user.id}&permissions=295157886134&scope=bot%20applications.commands`)
+ .setURL(`https://discord.com/api/oauth2/authorize?client_id=${client.user.id}&permissions=295157886134&scope=bot%20applications.commands`)
])], ephemeral: true});
}
diff --git a/src/commands/nucleus/ping.ts b/src/commands/nucleus/ping.ts
index ab23bf7..58413c6 100644
--- a/src/commands/nucleus/ping.ts
+++ b/src/commands/nucleus/ping.ts
@@ -2,6 +2,7 @@
import { SlashCommandSubcommandBuilder } from "@discordjs/builders";
import generateEmojiEmbed from "../../utils/generateEmojiEmbed.js";
import { WrappedCheck } from "jshaiku";
+import client from "../../utils/client.js"
const command = (builder: SlashCommandSubcommandBuilder) =>
builder
@@ -23,8 +24,8 @@
.setTitle("Ping")
.setDescription(
`**Ping:** \`${ping}ms\`\n` +
- `**To Discord:** \`${interaction.client.ws.ping}ms\`\n` +
- `**From Expected:** \`±${Math.abs((ping / 2) - interaction.client.ws.ping)}ms\``
+ `**To Discord:** \`${client.ws.ping}ms\`\n` +
+ `**From Expected:** \`±${Math.abs((ping / 2) - client.ws.ping)}ms\``
)
.setEmoji("CHANNEL.SLOWMODE.OFF")
.setStatus("Danger")
diff --git a/src/commands/nucleus/stats.ts b/src/commands/nucleus/stats.ts
index c12b950..1a0602e 100644
--- a/src/commands/nucleus/stats.ts
+++ b/src/commands/nucleus/stats.ts
@@ -2,6 +2,7 @@
import { SlashCommandSubcommandBuilder } from "@discordjs/builders";
import { WrappedCheck } from "jshaiku";
import generateEmojiEmbed from "../../utils/generateEmojiEmbed.js";
+import client from "../../utils/client.js"
const command = (builder: SlashCommandSubcommandBuilder) =>
builder
@@ -13,8 +14,8 @@
embeds: [new generateEmojiEmbed()
.setTitle("Stats")
.setDescription(
- `**Servers:** ${interaction.client.guilds.cache.size}\n` +
- `**Ping:** \`${interaction.client.ws.ping*2}ms\``
+ `**Servers:** ${client.guilds.cache.size}\n` +
+ `**Ping:** \`${client.ws.ping*2}ms\``
)
.setStatus("Success")
.setEmoji("GUILD.GRAPHS")
diff --git a/src/commands/nucleus/suggest.ts b/src/commands/nucleus/suggest.ts
index d1d6a03..c07d9b8 100644
--- a/src/commands/nucleus/suggest.ts
+++ b/src/commands/nucleus/suggest.ts
@@ -3,6 +3,7 @@
import { WrappedCheck } from "jshaiku";
import confirmationMessage from "../../utils/confirmationMessage.js";
import generateEmojiEmbed from "../../utils/generateEmojiEmbed.js";
+import client from "../../utils/client.js"
const command = (builder: SlashCommandSubcommandBuilder) =>
builder
@@ -12,7 +13,7 @@
const callback = async (interaction: CommandInteraction) => {
// @ts-ignore
- const { renderUser } = interaction.client.logger
+ const { renderUser } = client.logger
let suggestion = interaction.options.getString("suggestion");
let confirmation = await new confirmationMessage(interaction)
.setEmoji("ICONS.OPP.ADD")
@@ -23,7 +24,7 @@
.setInverted(true)
.send()
if (confirmation.success) {
- await (interaction.client.channels.cache.get('955161206459600976') as Discord.TextChannel).send({
+ await (client.channels.cache.get('955161206459600976') as Discord.TextChannel).send({
embeds: [
new generateEmojiEmbed()
.setTitle(`Suggestion`)