From e4312cd1ad17e8dda23ab2d1e0e58176244c3e12 Mon Sep 17 00:00:00 2001 From: SrIzan10 <66965250+SrIzan10@users.noreply.github.com> Date: Wed, 25 Oct 2023 22:05:23 +0200 Subject: [PATCH] fix: deprecated enums by discord.js (#108) * fix: deprecated enums by discord.js * chore: change version --- plugins/nsfwOnly.ts | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/plugins/nsfwOnly.ts b/plugins/nsfwOnly.ts index a0ae9e4..38afb7c 100644 --- a/plugins/nsfwOnly.ts +++ b/plugins/nsfwOnly.ts @@ -4,7 +4,8 @@ * This plugin checks if the channel is nsfw and responds to user with a specified response if not nsfw * * @author @Benzo-Fury [<@762918086349029386>] - * @version 1.0.0 + * @author @SrIzan10 [<@703974042700611634>] + * @version 1.0.1 * @example * ```ts * import { nsfwOnly } from "../plugins/nsfwOnly"; @@ -29,8 +30,8 @@ function isGuildText( channel: TextBasedChannel | null, ): channel is GuildTextBasedChannel { return ( - channel?.type == ChannelType.GuildPublicThread || - channel?.type == ChannelType.GuildPrivateThread + channel?.type == ChannelType.PublicThread || + channel?.type == ChannelType.PrivateThread ); } export function nsfwOnly(onFail: string, ephemeral: boolean) {