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 upsertPlainCustomer to be by email

Steven Tey8b1ad3c29b0d
diff --git a/apps/web/lib/plain/upsert-plain-customer.ts b/apps/web/lib/plain/upsert-plain-customer.ts
index 5a74692fb9..4f85917175 100644
--- a/apps/web/lib/plain/upsert-plain-customer.ts
+++ b/apps/web/lib/plain/upsert-plain-customer.ts
@@ -8,7 +8,7 @@ export const upsertPlainCustomer = async (
return await plain.upsertCustomer({
identifier: {
- externalId: user.id,
+ emailAddress: user.email,
},
onCreate: {
fullName,
@@ -26,9 +26,8 @@ export const upsertPlainCustomer = async (
shortName: {
value: shortName,
},
- email: {
- email: user.email,
- isVerified: true,
+ externalId: {
+ value: user.id,
},
},
});