Omniscia Tokemak Audit
BaseController Code Style Findings
BaseController Code Style Findings
BCR-01C: Redundant Type Casting
Type | Severity | Location |
---|---|---|
Code Style | ![]() | BaseController.sol:L11, L16 |
Description:
The linked statements perform an interface type casting of an input address
argument.
Example:
contracts/controllers/BaseController.sol
11constructor(address _manager, address _addressRegistry) public {12 require(_manager != address(0), "INVALID_ADDRESS");13 require(_addressRegistry != address(0), "INVALID_ADDRESS");14
15 manager = _manager;16 addressRegistry = IAddressRegistry(_addressRegistry);17}
Recommendation:
We advise the input type to be changed directly, optimizing the code's legibility.
Alleviation:
The Tokemak team considered this exhibit but opted not to apply a remediation for it in the current iteration of the codebase.