The variable managerCutPercent
is defined as a constant but is not written in uppercase as per Solidity's style guide recommendations.
Affected code - https://github.com/Cyfrin/2024-08-MyCut/blob/946231db0fe717039429a11706717be568d03b54/src/Pot.sol#L20
In the Solidity code, the constant variable managerCutPercent
is defined as:
According to the Solidity style guide, constant variables should be named using uppercase letters with underscores separating words. This ensures clarity and consistency in the code, making it easier for developers to identify constants at a glance.
This issue does not pose a direct security threat but affects code readability and maintainability. Failing to adhere to naming conventions can lead to confusion among developers, especially in larger projects where consistent naming is crucial for understanding and managing the codebase.
Manual Review
To resolve this issue, rename the constant variable managerCutPercent to follow the recommended naming convention. The revised code should look like this:
This change will align the code with the Solidity style guide and improve the overall readability and maintainability of the smart contract. See the Solidity Naming Convensions for more info.
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.