Updated types for channels

This commit is contained in:
2024-01-06 23:28:37 +01:00
parent 2b92750778
commit d06e15c96c
15 changed files with 43 additions and 147 deletions

View File

@@ -1,4 +1,4 @@
import { ChatInputCommandInteraction, GuildTextBasedChannel, channelMention } from "discord.js"
import { ChatInputCommandInteraction, TextChannel, channelMention } from "discord.js"
import settingsSchema from "../../schemas/settingsSchema"
import { color, devMessage } from "../../../config/options.json"
import mongoose from "mongoose"
@@ -6,7 +6,7 @@ import mongoose from "mongoose"
export default async function setup(interaction: ChatInputCommandInteraction): Promise<void> {
await interaction.deferReply()
const channel = interaction.options.getChannel("channel") as GuildTextBasedChannel
const channel = interaction.options.getChannel("channel") as TextChannel
const embedColor = Number(color.replace("#", "0x"))
if (await settingsSchema.findOne({ name: "counting" })) {