diff --git a/api/orders/history.cfm b/api/orders/history.cfm index d197b1e..85b05e5 100644 --- a/api/orders/history.cfm +++ b/api/orders/history.cfm @@ -109,8 +109,8 @@ try { AND (OrderLineItemIsDeleted = 0 OR OrderLineItemIsDeleted IS NULL) ", { orderId: { value = row.OrderID, cfsqltype = "cf_sql_integer" } }); - itemCount = qItems.ItemCount ?: 0; - subtotal = qItems.Subtotal ?: 0; + itemCount = val(qItems.ItemCount); + subtotal = val(qItems.Subtotal); tax = subtotal * 0.0875; total = subtotal + tax;