From 190003d648056ad6dfcf1f77e26b347337d2cdd4 Mon Sep 17 00:00:00 2001 From: thororen1234 <78185467+thororen1234@users.noreply.github.com> Date: Mon, 13 Oct 2025 22:20:07 -0400 Subject: [PATCH] UserPFP: Support Param --- src/equicordplugins/userpfp/index.tsx | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/equicordplugins/userpfp/index.tsx b/src/equicordplugins/userpfp/index.tsx index fa8c1dd44..2a0d50032 100644 --- a/src/equicordplugins/userpfp/index.tsx +++ b/src/equicordplugins/userpfp/index.tsx @@ -55,8 +55,13 @@ export default definePlugin({ if (settings.store.preferNitro && user.avatar?.startsWith("a_")) return original(user, animated, size); if (!data.avatars[user.id]) return original(user, animated, size); - const res = data.avatars[user.id]; - return animated ? res : res.replace(".gif", ".png"); + const res = new URL(data.avatars[user.id]); + res.searchParams.set("animated", animated ? "true" : "false"); + if (res && !animated) { + res.pathname = res.pathname.replaceAll(/\.gifv?/g, ".png"); + } + + return res.toString(); }, async start() { await fetch(API_URL)