diff --git a/src/commands/Slash/Utility/247.js b/src/commands/Slash/Utility/247.js index d0d3c35..2511626 100644 --- a/src/commands/Slash/Utility/247.js +++ b/src/commands/Slash/Utility/247.js @@ -22,6 +22,8 @@ module.exports = { await interaction.deferReply({ ephemeral: true }); const data = await Guild.findOne({ Id: interaction.guild.id }); + if (!data) await client.createInteraction(interaction); + const reconnect = data.reconnect; if (reconnect.status === true) { diff --git a/src/events/botEvents/guild/interactionCreate.js b/src/events/botEvents/guild/interactionCreate.js index 6dcee60..540c22d 100644 --- a/src/events/botEvents/guild/interactionCreate.js +++ b/src/events/botEvents/guild/interactionCreate.js @@ -4,11 +4,11 @@ const User = require("../../../settings/models/User.js"); module.exports.run = async (client, interaction) => { if (interaction.type === InteractionType.ApplicationCommand) { + await client.createInteraction(interaction); + const command = client.slashCommands.get(interaction.commandName); const user = client.premium.get(interaction.user.id); - await client.createInteraction(interaction); - if (!command) return; const row = new ActionRowBuilder().addComponents(