@pisell/pisellos 1.0.26 → 1.0.27
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1280,7 +1280,7 @@ export var BookingByStepImpl = /*#__PURE__*/function (_BaseModule) {
|
|
|
1280
1280
|
var originResource = allOriginResources.find(function (n) {
|
|
1281
1281
|
return n.id === targetRes.id;
|
|
1282
1282
|
});
|
|
1283
|
-
var canUse = checkResourceCanUseByCapacity(currentResourcesCapacityMap[m.id], currentCapacity, originResource === null || originResource === void 0 ? void 0 : originResource.capacity);
|
|
1283
|
+
var canUse = checkResourceCanUseByCapacity(currentResourcesCapacityMap[m.id] || 0, currentCapacity, originResource === null || originResource === void 0 ? void 0 : originResource.capacity);
|
|
1284
1284
|
if (canUse) currentResourcesCapacityMap[m.id] += currentCapacity;
|
|
1285
1285
|
return !canUse;
|
|
1286
1286
|
}
|
|
@@ -712,7 +712,7 @@ var BookingByStepImpl = class extends import_BaseModule.BaseModule {
|
|
|
712
712
|
(n) => n.id === targetRes.id
|
|
713
713
|
);
|
|
714
714
|
const canUse = (0, import_capacity.checkResourceCanUseByCapacity)(
|
|
715
|
-
currentResourcesCapacityMap[m.id],
|
|
715
|
+
currentResourcesCapacityMap[m.id] || 0,
|
|
716
716
|
currentCapacity,
|
|
717
717
|
originResource == null ? void 0 : originResource.capacity
|
|
718
718
|
);
|