Adjusted Slash Command Scope (#91)

* Update: Slash Command Scope

* Update: version increment
This commit is contained in:
Kevin Dang
2024-07-31 06:19:23 -07:00
committed by GitHub
parent 352d88ee9d
commit 060494e883
7 changed files with 8 additions and 9 deletions

View File

@@ -20,7 +20,7 @@ export const MessageStream: SlashCommand = {
run: async (client: Client, interaction: CommandInteraction) => {
// verify channel
const channel = await client.channels.fetch(interaction.channelId)
if (!channel || channel.type !== (ChannelType.PublicThread && ChannelType.GuildText)) return
if (!channel || channel.type !== (ChannelType.PrivateThread && ChannelType.PublicThread && ChannelType.GuildText)) return
// save value to json and write to it
openConfig(`${interaction.user.username}-config.json`, interaction.commandName, interaction.options.get('stream')?.value)