Omniscia Steer Protocol Audit
LiquidityManagerHelper Code Style Findings
LiquidityManagerHelper Code Style Findings
LMH-01C: Deprecated Revert Pattern
| Type | Severity | Location |
|---|---|---|
| Gas Optimization | ![]() | LiquidityManagerHelper.sol: • I-1: L240 • I-2: L244 |
Description:
The referenced revert statements will use a string argument which has been deprecated.
Example:
src/helpers/LiquidityManagerHelper.sol
238// 1. Get the newest attestation uid (zero if the wallet never verified)239bytes32 uid = INDEXER.getAttestationUid(to, VERIFIED_ACCOUNT_SCHEMA);240if (uid == bytes32(0)) revert("Not CBV");241
242// 2. Make sure it has NOT been revoked243(,,,, bool revoked,,) = EAS.getAttestation(uid);244if (revoked) revert("Not CBV");Recommendation:
We advise an actual error to be declared and used in each instance, optimizing the code's gas cost and bytecode size.
Alleviation:
Both instances were updated to yield custom error declarations, addressing this exhibit.
