Skip to content

Commit 57f9fef

Browse files
driskellnmalevanec
authored andcommitted
Magento PayPal checkout fails if email sending fails / other payment method does not
1 parent 05a7954 commit 57f9fef

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
@@ -809,8 +809,12 @@ public function place($token, $shippingMethodCode = null)
809809
case \Magento\Sales\Model\Order::STATE_PROCESSING:
810810
case \Magento\Sales\Model\Order::STATE_COMPLETE:
811811
case \Magento\Sales\Model\Order::STATE_PAYMENT_REVIEW:
812-
if (!$order->getEmailSent()) {
813-
$this->orderSender->send($order);
812+
try {
813+
if (!$order->getEmailSent()) {
814+
$this->orderSender->send($order);
815+
}
816+
} catch (\Exception $e) {
817+
$this->_logger->critical($e);
814818
}
815819
$this->_checkoutSession->start();
816820
break;

0 commit comments

Comments
 (0)