Omniscia Echidna Finance Audit
PtpDepositor Static Analysis Findings
PtpDepositor Static Analysis Findings
PDR-01S: Conditional Tautology
Type | Severity | Location |
---|---|---|
Gas Optimization | Informational | PtpDepositor.sol:L43 |
Description:
The linked conditional validates a tautology that will always yield true
.
Example:
contracts/core/PtpDepositor.sol
43if (_lockIncentive >= 0 && _lockIncentive <= 30) {
Recommendation:
We advise the greater-than-or-equal-to (>=
) comparison with zero to be omitted.
Alleviation:
The tautology component of the conditional was properly omitted from the codebase.
PDR-02S: Redundant bool
Variable Comparison
Type | Severity | Location |
---|---|---|
Gas Optimization | Informational | PtpDepositor.sol:L58, L102, L135 |
Description:
The linked statements perform a direct comparison between a bool
variable and a bool
literal.
Example:
contracts/core/PtpDepositor.sol
135require(isShutdown == false);
Recommendation:
We advise the bool
variable to be utilized directly instead either in its normal or negated (!
) form.
Alleviation:
The bool
variable is now utilized directly.