The credit capacity check in redeem()
uses .lte()
instead of .gte()
which causes withdrawals to revert when there is sufficient credit capacity and succeed when there isn't enough.
In redeem()
, the credit capacity check uses .lte()
to compare the credit capacity delta with locked credit capacity.
But in fact, it should revert when the credit capacity delta is greater than the locked credit capacity.
Withdrawals will incorrectly revert when there is sufficient locked credit capacity and succeed when there isn't enough credit capacity to facilitate the withdrawal.
Change the comparison operator from .lte()
to .gte()
to properly validate that there is enough locked credit capacity for the withdrawal.
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.