From c969f48fcc4bddd8d3bcbf9077c40e9de8e4415d Mon Sep 17 00:00:00 2001 From: hamid zarghami Date: Wed, 30 Apr 2025 16:43:33 +0330 Subject: [PATCH] fix bug --- src/pages/customer/Update.tsx | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/pages/customer/Update.tsx b/src/pages/customer/Update.tsx index c23723d..470a1d7 100644 --- a/src/pages/customer/Update.tsx +++ b/src/pages/customer/Update.tsx @@ -112,12 +112,12 @@ const UpdateCustomer: FC = () => { birthDate: data.birthDate || '', nationalCode: data.nationalCode || '', password: data.password || '', - economicCode: legal.economicCode || '', - registrationName: legal.registrationName || '', - registrationCode: legal.registrationCode || '', - nationalIdentity: legal.nationalIdentity || '', - postalCode: legal.address.postalCode || '', - address: legal.address?.fullAddress || '', + economicCode: legal?.economicCode || '', + registrationName: legal?.registrationName || '', + registrationCode: legal?.registrationCode || '', + nationalIdentity: legal?.nationalIdentity || '', + postalCode: legal?.address?.postalCode || '', + address: legal?.address?.fullAddress || '', cityId: legal?.address?.city?.id, profilePic: data.profilePic || '' });