You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
_EIP712NameHash and _EIP712VersionHash don't cache the hashes.
💻 Environment
EIP712Upgradeable.sol
Suggestions
Since this is an upgradeable contract, _EIP712NameHash and _EIP712VersionHash should simply return the hashes as byte32 literals or constants.
To ensure correctness, the equality of the _nameHash == keccak256(_name) can be checked in the initializer or use inline hash computation to initialize the constant.
With that being said, the storage slot is not needed in EIP712Upgradeable contract.
_EIP712NameHash
and_EIP712VersionHash
don't cache the hashes.💻 Environment
EIP712Upgradeable.sol
Suggestions
Since this is an upgradeable contract,
_EIP712NameHash
and_EIP712VersionHash
should simply return the hashes as byte32 literals or constants.To ensure correctness, the equality of the
_nameHash == keccak256(_name)
can be checked in the initializer or use inline hash computation to initialize the constant.With that being said, the storage slot is not needed in EIP712Upgradeable contract.
The text was updated successfully, but these errors were encountered: