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: pass cleared subscriptionCanceledAt in sale payloads

Cursor Agent63770f4833dc
diff --git a/apps/web/app/(ee)/api/stripe/integration/webhook/invoice-paid.ts b/apps/web/app/(ee)/api/stripe/integration/webhook/invoice-paid.ts
index 0880e4814c..42b1242d11 100644
--- a/apps/web/app/(ee)/api/stripe/integration/webhook/invoice-paid.ts
+++ b/apps/web/app/(ee)/api/stripe/integration/webhook/invoice-paid.ts
@@ -395,7 +395,7 @@ export async function invoicePaid({
...saleData,
clickedAt: customer.clickedAt || customer.createdAt,
link: linkUpdated,
- customer,
+ customer: { ...customer, subscriptionCanceledAt: null },
partner: result?.webhookPartner,
metadata: null,
}),
@@ -424,7 +424,7 @@ export async function invoicePaid({
...saleData,
clickedAt: customer.clickedAt || customer.createdAt,
link: linkUpdated,
- customer,
+ customer: { ...customer, subscriptionCanceledAt: null },
},
}),
]