diff --git a/backend/src/plugins/Utility/commands/CleanCmd.ts b/backend/src/plugins/Utility/commands/CleanCmd.ts index 60e79f26..50153982 100644 --- a/backend/src/plugins/Utility/commands/CleanCmd.ts +++ b/backend/src/plugins/Utility/commands/CleanCmd.ts @@ -84,7 +84,7 @@ export async function cleanCmd(pluginData: GuildPluginData, a } const targetChannel = args.channel ? pluginData.guild.channels.cache.get(args.channel as Snowflake) : msg.channel; - if (!targetChannel || !(targetChannel instanceof TextChannel)) { + if (!targetChannel?.isText()) { sendErrorMessage(pluginData, msg.channel, `Invalid channel specified`); return; }