From 645749b5ae59ccd9d536fa52b4eecdbc57af2a7d Mon Sep 17 00:00:00 2001 From: Hugo C Date: Wed, 2 Aug 2023 02:27:10 +0200 Subject: VoiceMessages: Improve permission check (#1544) Co-authored-by: V --- src/plugins/voiceMessages/index.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/plugins/voiceMessages/index.tsx b/src/plugins/voiceMessages/index.tsx index b5b9c73..40578a6 100644 --- a/src/plugins/voiceMessages/index.tsx +++ b/src/plugins/voiceMessages/index.tsx @@ -220,7 +220,7 @@ function Modal({ modalProps }: { modalProps: ModalProps; }) { } const ctxMenuPatch: NavContextMenuPatchCallback = (children, props) => () => { - if (props.channel.guild_id && !PermissionStore.can(PermissionsBits.SEND_VOICE_MESSAGES, props.channel)) return; + if (props.channel.guild_id && !(PermissionStore.can(PermissionsBits.SEND_VOICE_MESSAGES, props.channel) && PermissionStore.can(PermissionsBits.SEND_MESSAGES, props.channel))) return; children.push(