Skip to content

Commit

Permalink
MOL-1196: fix automatic shipping and add error logs (#685)
Browse files Browse the repository at this point in the history
* MOL-1196: fix automatic shipping and add error logs

* MOL-1196: remove comment

---------

Co-authored-by: Vitalij Mik <[email protected]>
  • Loading branch information
BlackScorp and Vitalij Mik authored Jan 16, 2024
1 parent 32b0be3 commit 1900474
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions src/Service/OrderDeliveryService.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ public function getDelivery(string $orderDeliveryId, Context $context): ?OrderDe
{
$criteria = new Criteria([$orderDeliveryId]);
$criteria->addAssociation('order.transactions.paymentMethod');
$criteria->addAssociation('order.deliveries');
$criteria->addAssociation('shippingMethod');
$result = $this->orderDeliveryRepository->search($criteria, $context);

Expand Down
2 changes: 1 addition & 1 deletion src/Subscriber/OrderDeliverySubscriber.php
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ public function onOrderDeliveryChanged(StateMachineStateChangeEvent $event): voi

$this->mollieShipment->shipOrderRest($order, null, $event->getContext());
} catch (\Throwable $ex) {
# do nothing in error in subscriber
$this->logger->error('Failed to transfer delivery state to mollie: '.$ex->getMessage());
return;
}
}
Expand Down

0 comments on commit 1900474

Please sign in to comment.