Function convertAccumulatedFeesToWeth approve the collateral token.
ERC20 functions may not behave as expected. For example: return values are not always meaningful.
ERC-20 functions like approve()
, transfer()
, and transferFrom()
do not always behave as expected.
Some tokens do not return a boolean (true/false) when calling these functions.
Others return false instead of reverting on failure, meaning the transaction does not revert but still fails silently.
If a token fails to approve, the contract will not know, and the transaction will continue as if the approval was successful, leading to unexpected behavior or security risks.
Manual review
It is recommended to use OpenZeppelin's SafeERC20 library, and replace approve
with safeApprove
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.