fix: Fix for edit user with null phone

fix for edit user with null phone

Change-Id: I09ae91ef69f4d0865f9fbacfa8dfab8131821096
This commit is contained in:
zhuyue 2021-11-15 11:38:34 +08:00
parent d261aaf92a
commit eb12eb9e3e

View File

@ -95,7 +95,7 @@ export class EditForm extends ModalAction {
const project = projects.filter((it) => it.id === default_project_id)[0];
if (name && this.formRef.current) {
const formatedPhone = parsePhoneNumberFromString(phone || '', 'CN') || {
country: 'CN',
countryCallingCode: '86',
nationalNumber: '',
};
const { countryCallingCode, nationalNumber } = formatedPhone;