From 9a3b9196d029f9294ed44a5ba6632defaae8fcdf Mon Sep 17 00:00:00 2001 From: dshukertjr <18113850+dshukertjr@users.noreply.github.com> Date: Fri, 24 Jun 2022 08:54:50 +0900 Subject: [PATCH] fix: send NOT_PROVIDED if certain form field was not entered --- apps/www/supabase/functions/hubspot-notification/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/www/supabase/functions/hubspot-notification/index.ts b/apps/www/supabase/functions/hubspot-notification/index.ts index e26d917cfee..00fd315ed26 100644 --- a/apps/www/supabase/functions/hubspot-notification/index.ts +++ b/apps/www/supabase/functions/hubspot-notification/index.ts @@ -50,7 +50,7 @@ serve(async (req) => { const fields: { objectTypeId: '0-1'; name: string; value: string }[] = [] for (const [key, value] of Object.entries(formData)) { - fields.push({ objectTypeId: '0-1', name: key, value: value }) + fields.push({ objectTypeId: '0-1', name: key, value: value || 'NOT_PROVIDED' }) } const formId = input.table === 'partner_contacts' ? PARTNER_FORM_ID : ENTERPRISE_FORM_ID