Skip to content
Request an audit

‹ Findings database

In AggregateHook, several if (newAmount == 0) checks are ambiguous

Low/InfoMitosis audit·Three Sigma·Cross-chain liquidity layer 1·25th June, 20243S-Mitosis-N19

Description

In AggregateHook::reportRedeem(), AggregateHook::previewReportClaim() and AggregateHook::reportClaim(), it sets newAmount to prevAmount if newAmount is null, which is always, as it is initialized by default to null.

Recommendation

Modify the code to make the intent more clear.

Status

Addressed in #b9b9ef0.