73 $customerForm = $this->formFactory->create(
82 $allowedAttributes = $customerForm->getAllowedAttributes();
83 $isGroupIdEmpty = isset($allowedAttributes[
'group_id']);
85 $customerDataObject = $this->customerFactory->create();
86 $this->dataObjectHelper->populateWithArray(
91 $store = $this->storeManager->getStore();
92 if ($isGroupIdEmpty) {
93 $customerDataObject->setGroupId(
94 $this->customerGroupManagement->getDefaultGroup(
$store->getId())->getId()
98 $customerDataObject->setWebsiteId(
$store->getWebsiteId());
99 $customerDataObject->setStoreId(
$store->getId());
101 return $customerDataObject;