Skip to content

Fix unavailable capacity calculation

Arran Walker requested to merge fix-max-use-capacity into main

The unavailable count was including the acquired count. This had an affect on scaling, but also meant that the potential returned from Capacity would panic, as it was possible for it to be negative.

I've added some tests that would previously have caused the code to panic due to the negative count, and updated tests now that unavailable and acquired are separate.

Edited by Arran Walker

Merge request reports