Skip to content

Commit 1b2a3f5

Browse files
author
Stanislav Idolov
authored
MAGETWO-86712: Magento PayPal checkout fails if email sending fails / other payment does not #13133
2 parents 0e835c9 + 3026dfb commit 1b2a3f5

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

app/code/Magento/Paypal/Model/Express/Checkout.php

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -810,8 +810,12 @@ public function place($token, $shippingMethodCode = null)
810810
case \Magento\Sales\Model\Order::STATE_PROCESSING:
811811
case \Magento\Sales\Model\Order::STATE_COMPLETE:
812812
case \Magento\Sales\Model\Order::STATE_PAYMENT_REVIEW:
813-
if (!$order->getEmailSent()) {
814-
$this->orderSender->send($order);
813+
try {
814+
if (!$order->getEmailSent()) {
815+
$this->orderSender->send($order);
816+
}
817+
} catch (\Exception $e) {
818+
$this->_logger->critical($e);
815819
}
816820
$this->_checkoutSession->start();
817821
break;

0 commit comments

Comments
 (0)