From 0d87396461833b23aaaf733aaa6f03e4889f4224 Mon Sep 17 00:00:00 2001 From: IRONM00N <64110067+IRONM00N@users.noreply.github.com> Date: Thu, 2 Jun 2022 18:08:43 -0400 Subject: fix: allow vc channels to be locked --- src/lib/extensions/discord.js/BushGuild.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/lib') diff --git a/src/lib/extensions/discord.js/BushGuild.ts b/src/lib/extensions/discord.js/BushGuild.ts index 80755bc..a93e35f 100644 --- a/src/lib/extensions/discord.js/BushGuild.ts +++ b/src/lib/extensions/discord.js/BushGuild.ts @@ -4,6 +4,7 @@ import { BushGuildChannelManager, BushGuildMemberManager, BushMessage, + BushVoiceChannel, dmResponse, permissionsResponse, punishmentEntryRemove, @@ -408,7 +409,7 @@ export class BushGuild extends Guild { const ret = await (async (): Promise => { for (const _channel of mappedChannels) { const channel = _channel!; - if (!channel.isText() && !channel.isThread()) { + if (!channel.isTextBased()) { errors.set(channel.id, new Error('wrong channel type')); success.set(channel.id, false); continue; @@ -761,7 +762,7 @@ export interface LockdownOptions { /** * A specific channel to lockdown */ - channel?: BushThreadChannel | BushNewsChannel | BushTextChannel; + channel?: BushThreadChannel | BushNewsChannel | BushTextChannel | BushVoiceChannel; /** * Whether or not to unlock the channel(s) instead of locking them -- cgit