Fixed the getCurrentFillFraction method