Skip to content

Commit

Permalink
CORE-600 Make sure the yves to zed call does not result in an unncess…
Browse files Browse the repository at this point in the history
…ary exception log in new relic.
  • Loading branch information
dereuromark committed Sep 28, 2016
1 parent a72e5be commit 091691c
Showing 1 changed file with 7 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
use Generated\Shared\Transfer\CustomerResponseTransfer;
use Generated\Shared\Transfer\CustomerTransfer;
use Spryker\Zed\Customer\Business\Exception\AddressNotFoundException;
use Spryker\Zed\Customer\Business\Exception\CustomerNotFoundException;
use Spryker\Zed\Kernel\Communication\Controller\AbstractGatewayController;

/**
Expand Down Expand Up @@ -105,10 +106,12 @@ public function hasCustomerWithEmailAndPasswordAction(CustomerTransfer $customer
*/
public function customerAction(CustomerTransfer $customerTransfer)
{
$result = $this->getFacade()
->getCustomer($customerTransfer);

return $result;
try {
return $this->getFacade()
->getCustomer($customerTransfer);
} catch (CustomerNotFoundException $e) {
return $customerTransfer;
}
}

/**
Expand Down

0 comments on commit 091691c

Please sign in to comment.