Omniscia Seen Haus Audit

SaleEnderFacet Code Style Findings

SaleEnderFacet Code Style Findings

SEF-01C: Redundant Evaluation

TypeSeverityLocation
Gas OptimizationInformationalSaleEnderFacet.sol:L71

Description:

The linked require check is redundant as the one that follows it guarantees its success.

Example:

contracts/market/handlers/facets/SaleEnderFacet.sol
71require(sale.state != State.Ended, "Sale has already been settled");
72require(sale.state == State.Running, "Sale hasn't started");

Recommendation:

We advise it to be omitted from the codebase.

Alleviation:

The redundant state comparison has been safely omitted.