This issue has to do with a conditional that checks if a value less than or equal to zero. However, the use of <= 0 is incorrect for unsigned integers, such as uint128, which cannot represent negative values.
The conditional check if (depositedAmount - (withdrawnAmount + refundedAmount) <= 0) is logically flawed because uint128 variables in Solidity are always non-negative.
The current logic incorrectly implies that a negative value could exist, which is impossible with uint128. This could lead to unnecessary reverts and potentially disrupt contract operations that rely on precise balance checks.
The use of <= 0 instead of == 0 introduces a logical error that can cause unnecessary transaction reverts, leading to disruptions in the expected functionality.
Manual review
Use == 0 instead of <= 0
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.