The modern link attribution platform. Loved by world-class engineering teams at Twilio, Zillow, Jobber, Vercel, Raycast, and more.
TypeScript clickhousemysqlnextjsopen-sourceplanetscaleprismatailwindcsstinybirdtypescriptupstashvercel
Update process-partner-group-change-job.ts
Kiran Ke2537e0f72d3
diff --git a/apps/web/lib/jobs/handlers/process-partner-group-change-job.ts b/apps/web/lib/jobs/handlers/process-partner-group-change-job.tsindex d14c7bd3ad..594dc9a026 100644--- a/apps/web/lib/jobs/handlers/process-partner-group-change-job.ts+++ b/apps/web/lib/jobs/handlers/process-partner-group-change-job.ts@@ -60,6 +60,15 @@ export const processPartnerGroupChangeJob = defineJob({}),]);+ // Remove LinkRewards for discount/reward+ await prisma.linkReward.deleteMany({+ where: {+ linkId: {+ in: pluck(partnerLinks, "id"),+ },+ },+ });+// If the userId is not provided, get the workspace user id from the workspace users// userId will be null for workflow-initiated actionslet workspaceUserId = userId;