Omniscia Evergon Labs Audit

DiamondFactory Static Analysis Findings

DiamondFactory Static Analysis Findings

DFY-01S: Multiple Top-Level Declarations

Description:

The referenced file contains multiple top-level declarations that decrease the legibility of the codebase.

Example:

packages/contracts/contracts/DiamondFactory.sol
8interface IAccess {
9 function initAccessControlFacet(address account) external;
10 function changeAdmin(address account) external;
11}
12
13/**
14 * @notice Factory for deploying and initializing Diamond Instances
15 */
16contract DiamondFactory is ERC2771Recipient {

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 (71cda4ccfdcfa25fb96a4565f1f8143b350dd246):

The IAccess interface (now aptly renamed to IAccessControlFacet) has been relocated to its dedicated file declaration optimizing the codebase's structure.