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.

Update webhooks.ts

Kiran Ke0acea5dfb89
diff --git a/apps/web/lib/zod/schemas/webhooks.ts b/apps/web/lib/zod/schemas/webhooks.ts
index 17830919b2..f7282ac562 100644
--- a/apps/web/lib/zod/schemas/webhooks.ts
+++ b/apps/web/lib/zod/schemas/webhooks.ts
@@ -77,12 +77,14 @@ export const createWebhookSchemaBase = z.object({
error:
"You can only select up to 1000 links. Recommended to use the 'Include specific folders' option instead.",
})
+ .transform((v) => [...new Set(v)])
.nullish(),
folderIds: z
.array(z.string())
.max(MAX_WEBHOOK_FOLDERS, {
error: `You can only select up to ${MAX_WEBHOOK_FOLDERS} folders.`,
})
+ .transform((v) => [...new Set(v)])
.nullish(),
});