Unverified Commit 4967ac47 authored by Krystian Podemski's avatar Krystian Podemski Committed by GitHub
Browse files

Merge pull request #28117 from NicolasCador/patch-2

Update function getCustomerOrders to avoid error
parents c353954b 01ad543c
......@@ -978,9 +978,9 @@ class OrderCore extends ObjectModel
foreach ($res as $key => $val) {
// In case order creation crashed midway some data might be absent
$orderState = !empty($val['id_order_state']) ? $indexedOrderStates[$val['id_order_state']] : null;
$res[$key]['order_state'] = $orderState['name'] ?: null;
$res[$key]['invoice'] = $orderState['invoice'] ?: null;
$res[$key]['order_state_color'] = $orderState['color'] ?: null;
$res[$key]['order_state'] = $orderState['name'] ?? null;
$res[$key]['invoice'] = $orderState['invoice'] ?? null;
$res[$key]['order_state_color'] = $orderState['color'] ?? null;
}
return $res;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment