From c975439e9ad1dca207ba8c285884e68b39885ad3 Mon Sep 17 00:00:00 2001 From: thororen1234 <78185467+thororen1234@users.noreply.github.com> Date: Sun, 28 Jul 2024 21:29:36 -0400 Subject: [PATCH] Fix Multiple Popups VCSupport --- src/plugins/_core/supportHelper.tsx | 29 +++++++++++++++++------------ 1 file changed, 17 insertions(+), 12 deletions(-) diff --git a/src/plugins/_core/supportHelper.tsx b/src/plugins/_core/supportHelper.tsx index ad28a2cf..cba19f1e 100644 --- a/src/plugins/_core/supportHelper.tsx +++ b/src/plugins/_core/supportHelper.tsx @@ -141,6 +141,8 @@ const settings = definePluginSettings({}).withPrivateSettings<{ dismissedDevBuildWarning?: boolean; }>(); +let clicked = false; + export default definePlugin({ name: "SupportHelper", required: true, @@ -177,18 +179,21 @@ export default definePlugin({ async CHANNEL_SELECT({ channelId }) { if (!SUPPORT_CHANNEL_IDS.includes(channelId)) return; - if (channelId === VC_SUPPORT_CHANNEL_ID && Vencord.Plugins.isPluginEnabled("VCSupport")) return Alerts.show({ - title: "You are entering the support channel!", - body:
- - - Before you ask for help, - Check for updates and if this - issue could be caused by Equicord! -
- }); + if (channelId === VC_SUPPORT_CHANNEL_ID && Vencord.Plugins.isPluginEnabled("VCSupport") && !clicked) { + clicked = true; + return Alerts.show({ + title: "You are entering the support channel!", + body:
+ + + Before you ask for help, + Check for updates and if this + issue could be caused by Equicord! +
+ }); + } const selfId = UserStore.getCurrentUser()?.id; if (!selfId || isPluginDev(selfId) || isEquicordPluginDev(selfId)) return;