Omniscia Steer Protocol Audit
LiquidityManagerHelper Static Analysis Findings
LiquidityManagerHelper Static Analysis Findings
LMH-01S: Multiple Top-Level Declarations
| Type | Severity | Location |
|---|---|---|
| Code Style | ![]() | LiquidityManagerHelper.sol:L17, L38 |
Description:
The referenced file contains multiple top-level declarations that decrease the legibility of the codebase.
Example:
src/helpers/LiquidityManagerHelper.sol
17interface IOracleHook {18 function observe(PoolKey calldata key, uint32[] calldata secondsAgos)19 external20 view21 returns (int48[] memory tickCumulatives, uint160[] memory secondsPerLiquidityCumulatives);22}23
24// Struct to hold variables for the preview burn operation to avoid stack too deep errors25struct PreviewBurnVars {26 uint128 liquidity;27 uint256 feeGrowth0Last;28 uint256 feeGrowth1Last;29 uint160 sqrtPriceX96;30 uint256 principal0;31 uint256 principal1;32 uint256 feeGrowth0Inside;33 uint256 feeGrowth1Inside;34 uint256 fees0;35 uint256 fees1;36}37
38contract LiquidityManagerHelper is IHelper {Recommendation:
We advise all highlighted top-level declarations to be split into their respective code files, avoiding unnecessary imports as well as increasing the legibility of the codebase.
Alleviation (121dc0b1329a48555f90bb92e58a95e8ff8a7c79):
A dedicated IOracle file has been introduced housing the IOracleHook interface that is now properly imported by the LiquidityManagerHelper, addressing this exhibit.
