/** * @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 \ProjectSeven\Exceptions\ClientException(\ProjectSeven\Notifications::InvalidInputParameter); } return $this->DefaultResponse($oAccount, __FUNCTION__, $this->oApiUsers->DeleteIdentity($iIdentityId)); }