/** * @param \Generated\Shared\Transfer\CustomerTransfer $customerTransfer * * @return \Generated\Shared\Transfer\CustomerResponseTransfer */ public function hasCustomerWithEmailAndPasswordAction(CustomerTransfer $customerTransfer) { $isAuthorized = $this->getFacade()->tryAuthorizeCustomerByEmailAndPassword($customerTransfer); $result = new CustomerResponseTransfer(); if ($isAuthorized === true) { $result->setCustomerTransfer($this->getFacade()->getCustomer($customerTransfer)); } $result->setHasCustomer($isAuthorized); $this->setSuccess($isAuthorized); return $result; }