Omniscia BlazeSwap Audit

SafeERC20Namer Code Style Findings

SafeERC20Namer Code Style Findings

SER-01C: Redundant Usage of Value Literals

Description:

The linked value literals are meant to represent the bytes4 selector of particular supplemental EIP-20 functions and are declared as hexadecimal literals with the selector commented above them.

Example:

contracts/shared/libraries/SafeERC20Namer.sol
74// 0x95d89b41 = bytes4(keccak256("symbol()"))
75string memory symbol = callAndParseStringReturn(token, 0x95d89b41);

Recommendation:

We advise the actual selector declaration style to be utilized instead whereby a particular interface (in this case IERC20Metadata) can be imported and its selectors defined in the code as such - IERC20Metadata.name.selector.

Alleviation:

The BlazeSwap team stated that this contract is a stub and thus should not have been in scope of the audit. As a result, we consider this exhibit nullified.