fix(charge): adding charges duplicates slot for which charge is added (#68)

This causes everything to become slower and slower.
This commit is contained in:
Patric Stout
2024-03-03 16:10:43 +01:00
committed by GitHub
parent 7fc6cc71cd
commit 566fd1d30f

View File

@@ -233,6 +233,7 @@ export const ShipSnapshotProvider = (props: ShipSnapshotProps) => {
)?.value;
if (moduleChargeSize !== undefined && moduleChargeSize !== chargeSize) {
newItems.push(item);
continue;
}
/* Check if the charge fits in this module; if so, assign it. */