/** * @return array */ public function AjaxAccountIdentityDelete() { $oAccount = $this->getAccountFromParam(); $iIdentityId = (int) $this->getParamValue('IdIdentity', 0); $oIdentity = $this->oApiUsers->getIdentity($iIdentityId); if (0 >= $iIdentityId || !$oIdentity || $oIdentity->IdUser !== $oAccount->IdUser || $oIdentity->IdAccount !== $oAccount->IdAccount) { throw new \ProjectCore\Exceptions\ClientException(\ProjectCore\Notifications::InvalidInputParameter); } return $this->DefaultResponse($oAccount, __FUNCTION__, $this->oApiUsers->deleteIdentity($iIdentityId)); }