diff --git a/packages/backend/src/services/fetch-rel-me.ts b/packages/backend/src/services/fetch-rel-me.ts index f7dbf72c1e..3e9f3c1184 100644 --- a/packages/backend/src/services/fetch-rel-me.ts +++ b/packages/backend/src/services/fetch-rel-me.ts @@ -6,10 +6,13 @@ async function getRelMeLinks(url: string): Promise { try { const html = await getHtml(url); const dom = new JSDOM(html); - const relMeLinks = [ - ...dom.window.document.querySelectorAll("a[rel='me']"), - ...dom.window.document.querySelectorAll("link[rel='me']"), - ].map((a) => (a as HTMLAnchorElement | HTMLLinkElement).href); + const allLinks = [...dom.window.document.querySelectorAll("a, link")]; + const relMeLinks = allLinks + .filter((a) => { + const relAttribute = a.getAttribute("rel"); + return relAttribute ? relAttribute.split(" ").includes("me") : false; + }) + .map((a) => (a as HTMLAnchorElement | HTMLLinkElement).href); return relMeLinks; } catch { return []; diff --git a/packages/client/src/pages/settings/profile.vue b/packages/client/src/pages/settings/profile.vue index 3b94a82488..fa33ac8876 100644 --- a/packages/client/src/pages/settings/profile.vue +++ b/packages/client/src/pages/settings/profile.vue @@ -127,8 +127,8 @@