Omniscia Gravita Protocol Audit
Code Style
Code Style
During the manual portion of the audit, we identified 60 optimizations that can be applied to the codebase that will decrease the operational cost associated with the execution of a particular function and generally ensure that the project complies with the latest best practices and standards in Solidity.
Additionally, this section of the audit contains any opinionated adjustments we believe the code should make to make it more legible as well as truer to its purpose.
These optimizations are enumerated below:
ID | Severity | Addressed | Title |
---|---|---|---|
APL-01C | ![]() | ![]() | Inefficient Renunciation of Ownership |
APL-02C | ![]() | ![]() | Inexplicable Ownable Pattern |
APL-03C | ![]() | ![]() | Redundant Initialization Paradigm |
ACT-01C | ![]() | ![]() | Inefficient mapping Lookups |
ACT-02C | ![]() | ![]() | Inexistent Error Message |
ACT-03C | ![]() | ![]() | Loop Iterator Optimizations |
ACT-04C | ![]() | ![]() | Misleading Variable Name |
BOS-01C | ![]() | ![]() | Ineffectual Native Value Check |
BOS-02C | ![]() | ![]() | Redundant Native Value Check |
BOS-03C | ![]() | ![]() | Suboptimal Struct Declaration Styles |
CSP-01C | ![]() | ![]() | Inefficient Renunciation of Ownership |
CSP-02C | ![]() | ![]() | Inefficient mapping Lookups |
CSP-03C | ![]() | ![]() | Inexplicable Ownable Pattern |
CSP-04C | ![]() | ![]() | Redundant Initialization Paradigm |
DTN-01C | ![]() | ![]() | Variable Mutability Specifier (Immutable) |
DPL-01C | ![]() | ![]() | Inefficient Renunciation of Ownership |
DPL-02C | ![]() | ![]() | Inefficient mapping Lookups |
DPL-03C | ![]() | ![]() | Inexplicable Ownable Pattern |
DPL-04C | ![]() | ![]() | Redundant Initialization Paradigm |
ERD-01C | ![]() | ![]() | Non-Standard Interface Name |
ERC-01C | ![]() | ![]() | Inefficient mapping Lookups |
ERC-02C | ![]() | ![]() | Multiple Top-Level Declarations |
ERC-03C | ![]() | ![]() | Redundant Low-Level Assembly Blocks |
ERC-04C | ![]() | ![]() | Variable Mutability Specifier (Immutable) |
FCR-01C | ![]() | ![]() | Inefficient mapping Lookups |
FCR-02C | ![]() | ![]() | Inexistent Error Messages |
FCR-03C | ![]() | ![]() | Leftover Test Code |
FCR-04C | ![]() | ![]() | Loop Iterator Optimization |
FCR-05C | ![]() | ![]() | Redundant Initialization Paradigm |
GBE-01C | ![]() | ![]() | Unused Function Declaration |
GMH-01C | ![]() | ![]() | Illegible Representation of Value Literal |
GMH-02C | ![]() | ![]() | Repetitive Value Literal |
PBE-01C | ![]() | ![]() | Significantly Inefficient Merging of Pending Gains / Distributed Funds |
PBE-02C | ![]() | ![]() | Unused Error Declaration |
PFD-01C | ![]() | ![]() | Inexistent Error Message |
PFD-02C | ![]() | ![]() | Redundant External Self-Calls |
PFD-03C | ![]() | ![]() | Redundant Function Implementation |
PFD-04C | ![]() | ![]() | Redundant Initialization Paradigm |
PFD-05C | ![]() | ![]() | Suboptimal Struct Declaration Styles |
RGU-01C | ![]() | ![]() | Inefficient Reentrancy Guard Implementation |
SVS-01C | ![]() | ![]() | Inefficient Renunciation of Ownership |
SVS-02C | ![]() | ![]() | Inefficient mapping Lookups |
SVS-03C | ![]() | ![]() | Inexplicable Ownable Pattern |
SVS-04C | ![]() | ![]() | Redundant Initialization Paradigm |
SPL-01C | ![]() | ![]() | Inefficient Renunciation of Ownership |
SPL-02C | ![]() | ![]() | Inefficient mapping Lookups |
SPL-03C | ![]() | ![]() | Inexplicable Contract Member |
SPL-04C | ![]() | ![]() | Inexplicable Ownable Pattern |
SPL-05C | ![]() | ![]() | Loop Iterator Optimizations |
SPL-06C | ![]() | ![]() | Redundant Initialization Paradigm |
SPL-07C | ![]() | ![]() | Suboptimal Struct Declaration Style |
TKC-01C | ![]() | ![]() | Inefficient Application of Access Control |
TKC-02C | ![]() | ![]() | Redundant Function Implementation |
VMR-01C | ![]() | ![]() | Inefficient mapping Lookups |
VMR-02C | ![]() | ![]() | Redundant Data Point |
VMR-03C | ![]() | ![]() | Redundant External Self-Call |
VMR-04C | ![]() | ![]() | Redundant Initialization Paradigm |
VMO-01C | ![]() | ![]() | Loop Iterator Optimizations |
VMO-02C | ![]() | ![]() | Redundant Initialization Paradigm |
VMO-03C | ![]() | ![]() | Suboptimal Struct Declaration Styles |