diff --git a/src/icon/favicon.ts b/src/icon/favicon.ts index 19ad1df..a6d7cfe 100644 --- a/src/icon/favicon.ts +++ b/src/icon/favicon.ts @@ -34,6 +34,16 @@ export function getFavicon( mask?: Image.Mask; }, ): Image.ImageLike { + // a func adding https:// to the URL + // for cases where the URL is not a full URL + // e.g. "raycast.com" + const withHttps = (url: string) => { + if (!url.startsWith("http")) { + return `https://${url}`; + } + return url; + }; + try { const sanitize = (url: string) => { if (!url.startsWith("http")) { diff --git a/tests/src/favicon.tsx b/tests/src/favicon.tsx index 2828aab..4a1f604 100644 --- a/tests/src/favicon.tsx +++ b/tests/src/favicon.tsx @@ -5,6 +5,7 @@ export default function Command() { return ( + ); }