Skip to content

armgit / dub

Public Imported from GitHub
0

The modern link attribution platform. Loved by world-class engineering teams at Twilio, Zillow, Jobber, Vercel, Raycast, and more.

fix broken link filter

Steven Teyf3ec0e6efb6e
diff --git a/apps/web/ui/analytics/toggle.tsx b/apps/web/ui/analytics/toggle.tsx
index 3368d1455a..c63084648a 100644
--- a/apps/web/ui/analytics/toggle.tsx
+++ b/apps/web/ui/analytics/toggle.tsx
@@ -511,8 +511,10 @@ export default function Toggle({
set:
key === "link"
? {
- domain: new URL(value).hostname,
- key: new URL(value).pathname.slice(1) || "_root",
+ domain: new URL(`https://${value}`).hostname,
+ key:
+ new URL(`https://${value}`).pathname.slice(1) ||
+ "_root",
}
: {
[key]: value,