diff --git a/applications/product/src/main/java/org/apache/ofbiz/shipment/packing/PackingSession.java b/applications/product/src/main/java/org/apache/ofbiz/shipment/packing/PackingSession.java index 8aad1b8c32..359212be0c 100644 --- a/applications/product/src/main/java/org/apache/ofbiz/shipment/packing/PackingSession.java +++ b/applications/product/src/main/java/org/apache/ofbiz/shipment/packing/PackingSession.java @@ -146,7 +146,8 @@ public class PackingSession implements java.io.Serializable { GenericValue res = EntityUtil.getFirst(reservations); BigDecimal resQty = numAvailableItems(res); - if (resQty.compareTo(quantity) > 0) { + // If reservation has enough for the quantity required + if (resQty.compareTo(quantity) >= 0) { int checkCode = this.checkLineForAdd(res, orderId, orderItemSeqId, shipGroupSeqId, productId, quantity, packageSeqId, update); this.createPackLineItem(checkCode, res, orderId, orderItemSeqId, shipGroupSeqId, productId, quantity, weight, packageSeqId); }