Redundant Storage Variable: user is declared but never used, wasting gas.
Misleading Liquidation Condition: The error message HealthFactorTooLow() is incorrect; it should indicate that liquidation is blocked when the health factor is too high.
Redundant storage variable :
user
is declared but never used in the function. userAddress
is directly used to fetch the required data.
2.Misleading revert statement :
When healthFactor of an user is higher than liquidation threshold it is considered to be a safe position. Hence the user should not be subjected to liquidation. But the revert statement is misleading as it interprets to " health factor being too low".
link to code
user is declared but never used, which wastes gas.
Misleading revert statement, if frontend depends on this revert statement it might give a wrong information.
Manual review
Remove the user
declaration.
2.Rename the error appropriately.
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.