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.

Stop writing the submitted lead form on the program

Rafib5abae169a8d
diff --git a/apps/web/lib/actions/partners/update-program.ts b/apps/web/lib/actions/partners/update-program.ts
index 09f9c7d5ff..3647e66e98 100644
--- a/apps/web/lib/actions/partners/update-program.ts
+++ b/apps/web/lib/actions/partners/update-program.ts
@@ -9,7 +9,6 @@ import {
} from "@/lib/constants/payouts";
import { getPlanCapabilities } from "@/lib/plan-capabilities";
import { prisma } from "@/lib/prisma";
-import { submittedLeadFormSchema } from "@/lib/zod/schemas/submitted-lead-form";
import { waitUntil } from "@vercel/functions";
import * as z from "zod/v4";
import { getProgramOrThrow } from "../../api/programs/get-program-or-throw";
@@ -20,7 +19,6 @@ import { throwIfNoPermission } from "../throw-if-no-permission";
const schema = updateProgramSchema.partial().extend({
workspaceId: z.string(),
applyHoldingPeriodDaysToAllGroups: z.boolean().optional(),
- referralFormData: submittedLeadFormSchema.optional(),
});
export const updateProgramAction = authActionClient
@@ -33,7 +31,6 @@ export const updateProgramAction = authActionClient
termsUrl,
minPayoutAmount,
messagingEnabledAt,
- referralFormData,
} = parsedInput;
throwIfNoPermission({
@@ -69,9 +66,6 @@ export const updateProgramAction = authActionClient
...(messagingEnabledAt !== undefined &&
(getPlanCapabilities(workspace.plan).canMessagePartners ||
messagingEnabledAt === null) && { messagingEnabledAt }),
- ...(referralFormData !== undefined && {
- referralFormData: referralFormData ?? null,
- }),
},
});
diff --git a/apps/web/lib/zod/schemas/programs.ts b/apps/web/lib/zod/schemas/programs.ts
index 1341fd13e5..fcbd1f0823 100644
--- a/apps/web/lib/zod/schemas/programs.ts
+++ b/apps/web/lib/zod/schemas/programs.ts
@@ -107,7 +107,6 @@ export const updateProgramSchema = z.object({
.max(500)
.nullish(),
messagingEnabledAt: z.coerce.date().nullish(),
- referralFormData: submittedLeadFormSchema.nullish(),
});
export const ProgramPartnerLinkSchema = LinkSchema.pick({