add back in USRBG support

This commit is contained in:
Luna 2024-05-29 16:52:06 -04:00
parent 17131fa739
commit 03d2691fff

View file

@ -82,8 +82,14 @@ export default definePlugin({
},
memberListBanner: ErrorBoundary.wrap(({ user }: { user: User; }) => {
let url = useFetchMemberProfile(user.id);
let url: string | null = null;
if (Vencord.Plugins.isPluginEnabled("USRBG")) {
const USRBG = Vencord.Plugins.plugins.USRBG as unknown as typeof import("../usrbg/index").default;
url = USRBG.getImageUrl(user.id);
}
if (!url) {
url = useFetchMemberProfile(user.id);
}
if (url === "") return null;
if (!settings.store.animate) url = url.replace(".gif", ".png");
return (