consent posts as a JSON boolean (the checkbox's literal 'on' never reaches the webhook)
This commit is contained in:
@@ -123,6 +123,9 @@ const note = type === "founders" ? strings.form_founders_note : strings.form_hub
|
||||
const data = new FormData(form);
|
||||
const payload = {};
|
||||
data.forEach((v, k) => { payload[k] = v; });
|
||||
// consent as a JSON boolean (the Flow/CRM mapping expects true/false,
|
||||
// not the checkbox's literal "on"; an unchecked box never arrives)
|
||||
payload.consent = data.get("consent") === "on";
|
||||
if (payload.website) return; // honeypot: pretend success, send nothing
|
||||
if (capField && !payload.capabilities) payload.capabilities = capField.value;
|
||||
button.disabled = true;
|
||||
|
||||
Reference in New Issue
Block a user