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 track-sale.ts

Kiran Kd032a8314725
diff --git a/apps/web/lib/integrations/hubspot/track-sale.ts b/apps/web/lib/integrations/hubspot/track-sale.ts
index 0df7cd6524..496cb171be 100644
--- a/apps/web/lib/integrations/hubspot/track-sale.ts
+++ b/apps/web/lib/integrations/hubspot/track-sale.ts
@@ -43,6 +43,11 @@ export const trackHubSpotSaleEvent = async ({
const { id: dealId, properties, associations } = deal;
+ if (!properties.amount) {
+ console.error(`[HubSpot] Amount is not set for deal ${dealId}`);
+ return;
+ }
+
// Find the contact associated with the deal
const contact = associations.contacts.results[0];