Omniscia Stakewise Audit
ERC20Upgradeable Static Analysis Findings
ERC20Upgradeable Static Analysis Findings
ERC-01S: Redundant Empty Code Block
| Type | Severity | Location |
|---|---|---|
| Code Style | Informational | ERC20Upgradeable.sol:L202 |
Description:
The _transfer function contains an empty code block as it is meant to be overridden by contracts that inherit the contract in question.
Example:
contracts/tokens/ERC20Upgradeable.sol
202function _transfer(address sender, address recipient, uint256 amount) internal virtual { }Recommendation:
In order to ensure that the function is always overridden, we advise the brackets to be omitted ({}) and the declaration to simply terminate with the ; character to mandate derivative contracts to override this method or not compile.
Alleviation:
The function now properly terminates with the ; character.