diff --git a/src/events/client/InteractionCreate.ts b/src/events/client/InteractionCreate.ts index 512b02201..a550898cb 100644 --- a/src/events/client/InteractionCreate.ts +++ b/src/events/client/InteractionCreate.ts @@ -22,6 +22,13 @@ export default class InteractionCreate extends Event { interaction instanceof CommandInteraction && interaction.type === InteractionType.ApplicationCommand ) { + const setup = await this.client.db.getSetup(interaction.guildId); + if ( + setup && + interaction.channelId === setup.textId + ) { +return interaction.reply({ content: `You can't use commands in setup channel.` , ephemeral: true}) + } const { commandName } = interaction; await this.client.db.get(interaction.guildId); // get or create guild data const command = this.client.commands.get(interaction.commandName);