fix: Contact form breaks if name is empty (#10597)

- Handles the case where the form and contact display page breaks if
name is `null`
This commit is contained in:
Sojan Jose
2024-12-17 17:16:50 +05:30
committed by GitHub
parent b34dac7bbe
commit 1d88e0dd28

View File

@@ -94,7 +94,7 @@ const prepareStateBasedOnProps = () => {
phoneNumber,
additionalAttributes = {},
} = props.contactData || {};
const { firstName, lastName } = splitName(name);
const { firstName, lastName } = splitName(name || '');
const {
description = '',
companyName = '',