20,000 USDC
View results
Submission Details
Severity: gas
Valid

Redundant If Statement

Summary

There is a redundant if statement in the update function.

Vulnerability Details

It is checked if _diff > 0, however, it is previously checked if the _balance > balance, which means that _diff > 0 will always be true at the moment of execution.

Impact

This will lead to the redundnat Gas consumption.

Tools Used

Manual review.

Recommendations

Remove the redundant if statement.

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.

Give us feedback!