From 2b926ba610f3dcd0dfa8b7f81e3f4c76db14d198 Mon Sep 17 00:00:00 2001 From: yxshv Date: Sat, 13 Apr 2024 20:53:36 +0530 Subject: [PATCH] fix edge case for getting metadata --- apps/web/src/server/helpers.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/apps/web/src/server/helpers.ts b/apps/web/src/server/helpers.ts index a20474b2..c7455a60 100644 --- a/apps/web/src/server/helpers.ts +++ b/apps/web/src/server/helpers.ts @@ -19,6 +19,8 @@ export async function getMetaData(url: string) { let favicon = _favicon.trim().length > 0 ? _favicon.trim() : 'https://supermemory.dhr.wtf/web.svg' if (favicon.startsWith("/")) { favicon = baseUrl + favicon + } else if (favicon.startsWith("./")) { + favicon = baseUrl + favicon.slice(1) } // Prepare the metadata object