CASH-715
CASH-715 undefined check
This commit is contained in:
parent
10503c0c8e
commit
473ac2ad66
1 changed files with 4 additions and 4 deletions
|
|
@ -3621,25 +3621,25 @@ export function mapTaxedLineItemsToStoreFormat(availableLineItems, storeLineItem
|
||||||
export function getArrayOfAllLineItemsAndChildParts(lineItems) {
|
export function getArrayOfAllLineItemsAndChildParts(lineItems) {
|
||||||
let consolidatedLineItemsArray = [];
|
let consolidatedLineItemsArray = [];
|
||||||
|
|
||||||
if (lineItems.glassParts != null)
|
if (lineItems?.glassParts != null)
|
||||||
consolidatedLineItemsArray = [
|
consolidatedLineItemsArray = [
|
||||||
...consolidatedLineItemsArray,
|
...consolidatedLineItemsArray,
|
||||||
...getFlattenedArrayOfLineItemsWithChildParts(lineItems.glassParts),
|
...getFlattenedArrayOfLineItemsWithChildParts(lineItems.glassParts),
|
||||||
];
|
];
|
||||||
|
|
||||||
if (lineItems.supportingItems != null)
|
if (lineItems?.supportingItems != null)
|
||||||
consolidatedLineItemsArray = [
|
consolidatedLineItemsArray = [
|
||||||
...consolidatedLineItemsArray,
|
...consolidatedLineItemsArray,
|
||||||
...getFlattenedArrayOfLineItemsWithChildParts(lineItems.supportingItems),
|
...getFlattenedArrayOfLineItemsWithChildParts(lineItems.supportingItems),
|
||||||
];
|
];
|
||||||
|
|
||||||
if (lineItems.vaps != null)
|
if (lineItems?.vaps != null)
|
||||||
consolidatedLineItemsArray = [
|
consolidatedLineItemsArray = [
|
||||||
...consolidatedLineItemsArray,
|
...consolidatedLineItemsArray,
|
||||||
...getFlattenedArrayOfLineItemsWithChildParts(lineItems.vaps),
|
...getFlattenedArrayOfLineItemsWithChildParts(lineItems.vaps),
|
||||||
];
|
];
|
||||||
|
|
||||||
if (lineItems.promos != null)
|
if (lineItems?.promos != null)
|
||||||
consolidatedLineItemsArray = [
|
consolidatedLineItemsArray = [
|
||||||
...consolidatedLineItemsArray,
|
...consolidatedLineItemsArray,
|
||||||
...getFlattenedArrayOfLineItemsWithChildParts(lineItems.promos),
|
...getFlattenedArrayOfLineItemsWithChildParts(lineItems.promos),
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue