Skip to content

Commit

Permalink
Small changes in order to send details from backend
Browse files Browse the repository at this point in the history
  • Loading branch information
vilgro committed Jun 14, 2018
1 parent 2d1623c commit dff0085
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Observer/OrderSaveObserver.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ public function execute(EventObserver $observer)
'orderStatusName' => $order->getStatusLabel(),
'hook' => 'sales_order_save_after'
];
if ($orderStatusId == \Magento\Sales\Model\Order::STATE_NEW) {
if ($orderStatusId == \Magento\Sales\Model\Order::STATE_NEW || $orderStatus == null) {
$data['recipientEmail'] = trim($this->_orderDataHelper->getEmail($order));
$data['recipientName'] = $order->getCustomerName();
$response = $this->_trustpilotHttpClient->postInvitation($key, $storeId, $data);
Expand Down

0 comments on commit dff0085

Please sign in to comment.