diff --git a/src/equicordplugins/vcSupport/index.ts b/src/equicordplugins/vcSupport/index.ts index cf29afbe..a7c958b0 100644 --- a/src/equicordplugins/vcSupport/index.ts +++ b/src/equicordplugins/vcSupport/index.ts @@ -5,11 +5,21 @@ */ import { EquicordDevs } from "@utils/constants"; +import { isEquicordPluginDev, isPluginDev } from "@utils/misc"; import definePlugin from "@utils/types"; +import { UserStore } from "@webpack/common"; export default definePlugin({ name: "VCSupport", description: "Wumpus Dance + Support Warnings", authors: [EquicordDevs.thororen, EquicordDevs.coolesding], - enabledByDefault: true + required: true, + start() { + const selfId = UserStore.getCurrentUser()?.id; + if (isPluginDev(selfId) || isEquicordPluginDev(selfId)) { + Vencord.Settings.plugins.VCSupport.enabled = false; + } else { + Vencord.Settings.plugins.VCSupport.enabled = true; + } + } }); diff --git a/src/plugins/_core/supportHelper.tsx b/src/plugins/_core/supportHelper.tsx index fa09561b..c33e0d98 100644 --- a/src/plugins/_core/supportHelper.tsx +++ b/src/plugins/_core/supportHelper.tsx @@ -22,7 +22,7 @@ import ErrorBoundary from "@components/ErrorBoundary"; import { Flex } from "@components/Flex"; import { Link } from "@components/Link"; import { openUpdaterModal } from "@components/VencordSettings/UpdaterTab"; -import { CONTRIB_ROLE_ID, Devs, DONOR_ROLE_ID, EQUCORD_HELPERS, EQUIBOP_CONTRIB_ROLE_ID, EQUICORD_TEAM, GUILD_ID, SUPPORT_CHANNEL_ID, VC_CONTRIB_ROLE_ID, VC_DONOR_ROLE_ID, VC_GUILD_ID, VC_REGULAR_ROLE_ID, VC_SUPPORT_CHANNEL_ID, VENCORD_CONTRIB_ROLE_ID } from "@utils/constants"; +import { CONTRIB_ROLE_ID, Devs, DONOR_ROLE_ID, EQUCORD_HELPERS, EQUIBOP_CONTRIB_ROLE_ID, EQUICORD_TEAM, GUILD_ID, SUPPORT_CHANNEL_ID, SUPPORT_CHANNEL_IDS, VC_CONTRIB_ROLE_ID, VC_DONOR_ROLE_ID, VC_GUILD_ID, VC_REGULAR_ROLE_ID, VC_SUPPORT_CHANNEL_ID, VENCORD_CONTRIB_ROLE_ID } from "@utils/constants"; import { sendMessage } from "@utils/discord"; import { Logger } from "@utils/Logger"; import { Margins } from "@utils/margins"; @@ -196,13 +196,12 @@ export default definePlugin({ flux: { async CHANNEL_SELECT({ channelId }) { - const isSupportChannel = channelId === SUPPORT_CHANNEL_ID; + const isSupportChannel = SUPPORT_CHANNEL_IDS.includes(channelId); if (!isSupportChannel) return; const selfId = UserStore.getCurrentUser()?.id; if (!selfId || isPluginDev(selfId) || isEquicordPluginDev(selfId)) return; if (channelId === VC_SUPPORT_CHANNEL_ID && Vencord.Plugins.isPluginEnabled("VCSupport") && !clicked) { - clicked = true; return Alerts.show({ title: "You are entering the support channel!", body: