15,000 USDC
View results
Submission Details
Severity: gas

Empty blocks should be removed or emit something

Summary

The code should be refactored such that empty blocks no longer exist

Vulnerability Details

The code should be refactored such that they no longer exist, or the block should do something useful, such as emitting an event or reverting

44 constructor() ERC20("DecentralizedStableCoin", "DSC") {}

https://github.com/Cyfrin/2023-07-foundry-defi-stablecoin/blob/main/src/DecentralizedStableCoin.sol#L44

Impact

Gas savings can be achieved

Tools Used

Manual review

Recommendations

The code should be refactored such that empty blocks no longer exist

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.