[O-1] Replace require
Statements with Custom Errors, only if solc version is 0.8.4 or higher.
As stated in the official release of (Solidity 0.8.4)[https://soliditylang.org/blog/2021/04/21/custom-errors/], utilizing custom errors can reduce runtime and deployment costs, as indicated by the following benchmark, while also improving clarity in error handling.
Likelihood: Low
Impact: None
Lets take the Game::nonReentrant
modifier as example:
This modifier requires the _locked
value to be false
in order to continue its logic.
Consider update to solidity version 0.8.4 or higher and replacing all require statements with custom errors.
Then you can add a custom error like this:
Consider to apply this methodology to replace all require
conditionals using the example above.
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.