The initiateLiquidation function contains a misleading revert message. The condition if (healthFactor >= healthFactorLiquidationThreshold) reverts with HealthFactorTooLow() when the Health Factor is above or equal to the liquidation threshold. This message is incorrect because it implies the Health Factor is too low, while in reality, the Health Factor is too high for liquidation to proceed.
The issue lies in the initiateLiquidation function in LendingPool.sol contract below:
The error occured in the line below
The revert message HealthFactorTooLow is misleading, as it suggests that the health factor is too low when the condition checks if it is too high.
The error message HealthFactorTooLow is also misleading, as it suggests that the health factor is too low when, in fact, the condition checks if it is too high.
Manual code review
Update the health factor check to correctly revert when the health factor is above the liquidation threshold:
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.