The function _redeemCollateral has an issue where the CollateralRedeemed event is emitted before the collateral token transfer occurs.
information being emitted in the event log if the token transfer fails due to reasons such as insufficient balance, token contract issues, or out-of-gas conditions. Emitting the event before ensuring a successful transfer could confuse external systems that rely on the emitted event to track collateral redemption activities.
This could confuse external systems that rely on the emitted event to track collateral redemption activities.
Manual Review
To rectify this issue and ensure that the event is emitted at the right time, the token transfer should be executed before emitting the event. This ensures that the event is only emitted if the transfer is successful, providing accurate and reliable information to external systems.
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.