CASH-1637
CASH-1637 check for array to prevent exception when not
This commit is contained in:
parent
85cad5a6ce
commit
58e2ec0add
1 changed files with 6 additions and 4 deletions
|
|
@ -237,10 +237,12 @@ export default {
|
|||
(lineItem) => lineItem.partType == partTypeStrings.EARLY_BIRD
|
||||
);
|
||||
|
||||
const promoCodes = order?.lineItems?.promos
|
||||
?.map((item) => item.promoCode)
|
||||
.filter((code) => code)
|
||||
.join(", ");
|
||||
const promoCodes = Array.isArray(order?.lineItems?.promos)
|
||||
? order?.lineItems?.promos
|
||||
?.map((item) => item.promoCode)
|
||||
.filter((code) => code)
|
||||
.join(", ")
|
||||
: "";
|
||||
|
||||
label = {};
|
||||
label.serviceType = order?.serviceLocation?.appointmentType;
|
||||
|
|
|
|||
Loading…
Reference in a new issue