From ee0eb2820efbae88daf52e20f33a15f2ff31d28f Mon Sep 17 00:00:00 2001 From: seb Date: Wed, 21 Oct 2026 04:28:58 +0200 Subject: [PATCH] u --- src/db/order.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/db/order.js b/src/db/order.js index f8957b3..c5df848 100644 --- a/src/db/order.js +++ b/src/db/order.js @@ -68,7 +68,7 @@ async function enrichSingleOrder(store, googleAuthId, order) { const shippedQuantity = calculateShippedQuantity(shipmentsList); const allShippings = shippingsList.length > 0 ? shippingsList : shipmentsList.flatMap((s) => s.shippings || []); - const isPaid = orderTotal > 0 && Math.abs(paidTotal - orderTotal) < 0.01; + const isPaid = Math.abs(orderTotal) < 0.01 || Math.abs(paidTotal - orderTotal) < 0.01; const isShipped = orderedQuantity > 0 && Math.abs(shippedQuantity - orderedQuantity) < 0.001; const isDelivered = isShipped || allShippings.some((s) => s.state === 'shipped' || s.state === 'delivered');