aboutsummaryrefslogtreecommitdiff
path: root/src/plugins
diff options
context:
space:
mode:
authorV <vendicated@riseup.net>2023-05-23 01:55:39 +0200
committerGitHub <noreply@github.com>2023-05-23 01:55:39 +0200
commit184c03b28e6df72f301f91862dc8bdfb5f074fcb (patch)
treea543a4e3c932d172e76d86365b590265dfa1b0ff /src/plugins
parentec091a79591cf9619dd589102f5b338827b70ad8 (diff)
downloadVencord-184c03b28e6df72f301f91862dc8bdfb5f074fcb.tar.gz
Vencord-184c03b28e6df72f301f91862dc8bdfb5f074fcb.tar.bz2
Vencord-184c03b28e6df72f301f91862dc8bdfb5f074fcb.zip
PluginModal: Anonymise authors (#1176)
Diffstat (limited to 'src/plugins')
-rw-r--r--src/plugins/apiBadges.tsx6
-rw-r--r--src/plugins/supportHelper.tsx4
2 files changed, 4 insertions, 6 deletions
diff --git a/src/plugins/apiBadges.tsx b/src/plugins/apiBadges.tsx
index 23ed6de..5f44d98 100644
--- a/src/plugins/apiBadges.tsx
+++ b/src/plugins/apiBadges.tsx
@@ -24,15 +24,13 @@ import { Heart } from "@components/Heart";
import { Devs } from "@utils/constants";
import { Logger } from "@utils/Logger";
import { Margins } from "@utils/margins";
+import { isPluginDev } from "@utils/misc";
import { closeModal, Modals, openModal } from "@utils/modal";
import definePlugin from "@utils/types";
import { Forms, Toasts } from "@webpack/common";
const CONTRIBUTOR_BADGE = "https://cdn.discordapp.com/attachments/1033680203433660458/1092089947126780035/favicon.png";
-/** List of vencord contributor IDs */
-const contributorIds: string[] = Object.values(Devs).map(d => d.id.toString());
-
const ContributorBadge: ProfileBadge = {
description: "Vencord Contributor",
image: CONTRIBUTOR_BADGE,
@@ -43,7 +41,7 @@ const ContributorBadge: ProfileBadge = {
transform: "scale(0.9)" // The image is a bit too big compared to default badges
}
},
- shouldShow: ({ user }) => contributorIds.includes(user.id),
+ shouldShow: ({ user }) => isPluginDev(user.id),
link: "https://github.com/Vendicated/Vencord"
};
diff --git a/src/plugins/supportHelper.tsx b/src/plugins/supportHelper.tsx
index db38b37..8b0880d 100644
--- a/src/plugins/supportHelper.tsx
+++ b/src/plugins/supportHelper.tsx
@@ -18,6 +18,7 @@
import { DataStore } from "@api/index";
import { Devs, SUPPORT_CHANNEL_ID } from "@utils/constants";
+import { isPluginDev } from "@utils/misc";
import { makeCodeblock } from "@utils/text";
import definePlugin from "@utils/types";
import { isOutdated } from "@utils/updater";
@@ -74,8 +75,7 @@ ${makeCodeblock(Object.keys(plugins).filter(Vencord.Plugins.isPluginEnabled).joi
async CHANNEL_SELECT({ channelId }) {
if (channelId !== SUPPORT_CHANNEL_ID) return;
- const myId = BigInt(UserStore.getCurrentUser().id);
- if (Object.values(Devs).some(d => d.id === myId)) return;
+ if (isPluginDev(UserStore.getCurrentUser().id)) return;
if (isOutdated && gitHash !== await DataStore.get(REMEMBER_DISMISS_KEY)) {
const rememberDismiss = () => DataStore.set(REMEMBER_DISMISS_KEY, gitHash);