From cde217a4afe09f33510d7a99c5355aad3b95caab Mon Sep 17 00:00:00 2001 From: Alex Taranovsky Date: Wed, 9 Oct 2019 12:44:11 +0300 Subject: [PATCH] magento/graphql-ce#985: Remove unnecessary exceptions --- .../Model/Customer/CheckCustomerPassword.php | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/app/code/Magento/CustomerGraphQl/Model/Customer/CheckCustomerPassword.php b/app/code/Magento/CustomerGraphQl/Model/Customer/CheckCustomerPassword.php index 3cc831e1ca40e..c252628b6566e 100644 --- a/app/code/Magento/CustomerGraphQl/Model/Customer/CheckCustomerPassword.php +++ b/app/code/Magento/CustomerGraphQl/Model/Customer/CheckCustomerPassword.php @@ -9,12 +9,8 @@ use Magento\Customer\Model\AuthenticationInterface; use Magento\Framework\Exception\InvalidEmailOrPasswordException; -use Magento\Framework\Exception\LocalizedException; -use Magento\Framework\Exception\NoSuchEntityException; use Magento\Framework\Exception\State\UserLockedException; use Magento\Framework\GraphQl\Exception\GraphQlAuthenticationException; -use Magento\Framework\GraphQl\Exception\GraphQlInputException; -use Magento\Framework\GraphQl\Exception\GraphQlNoSuchEntityException; /** * Check customer password @@ -41,8 +37,6 @@ public function __construct( * @param string $password * @param int $customerId * @throws GraphQlAuthenticationException - * @throws GraphQlInputException - * @throws GraphQlNoSuchEntityException */ public function execute(string $password, int $customerId) { @@ -52,10 +46,6 @@ public function execute(string $password, int $customerId) throw new GraphQlAuthenticationException(__($e->getMessage()), $e); } catch (UserLockedException $e) { throw new GraphQlAuthenticationException(__($e->getMessage()), $e); - } catch (NoSuchEntityException $e) { - throw new GraphQlNoSuchEntityException(__($e->getMessage()), $e); - } catch (LocalizedException $e) { - throw new GraphQlInputException(__($e->getMessage()), $e); } } }