mirror of
https://github.com/discordeno/discordeno.git
synced 2026-06-02 00:40:07 +00:00
fix wrong if logic again
This commit is contained in:
@@ -23,12 +23,7 @@ export async function editMember(guildId: bigint, memberId: bigint, options: Mod
|
||||
|
||||
if (options.roles) requiredPerms.add("MANAGE_ROLES");
|
||||
|
||||
if (
|
||||
typeof options.mute !== "undefined" ||
|
||||
typeof options.deaf !== "undefined" ||
|
||||
// "object" to do simple null check
|
||||
(typeof options.channelId !== "undefined" && typeof options.channelId !== "object")
|
||||
) {
|
||||
if (options.mute !== undefined || options.deaf !== undefined || options.channelId || options.channelId === null) {
|
||||
const memberVoiceState = (await cacheHandlers.get("guilds", guildId))?.voiceStates.get(memberId);
|
||||
|
||||
if (!memberVoiceState?.channelId) {
|
||||
|
||||
Reference in New Issue
Block a user