jaibhedia / VoteChain

Blockchain based E-Voting system.
https://npb-vote-web-3.vercel.app
MIT License
31 stars 54 forks source link

Require improvement in Contest.sol #62

Open AlexMercer00 opened 4 months ago

AlexMercer00 commented 4 months ago

Hi team

I'm a participant in GSSoC and I'm interested in working on this issue. Could you please assign it to me? List of Issues: 1.Outdated Solidity Version: The pragma solidity 0.5.16; line uses an old version of Solidity. Consider upgrading to a more recent version, like ^0.8.0. 2.Visibility Not Specified: The admin and state variables do not have explicit visibility. It's good practice to specify visibility (public, internal, etc.) for all state variables.

  1. Modifier Error Messages: The require statements in the modifiers onlyAdmin and validState should include error messages to aid in debugging and provide better feedback. 4.Function Name Style: The function voterRegistration should follow camelCase naming convention, which is the standard in Solidity. Rename it to voterRegistration. 5.Require Error Messages: The require statements within the vote function should include error messages to specify what condition failed. This helps in debugging and user feedback. By addressing these issues, the contract will be more robust, maintainable, and aligned with best practices in Solidity development. Could you please assign this issue to me? I'm keen to collaborate and contribute to enhancing the security.

Thank you!

Best regards, Ashutosh Singh (GSSOC Participant)

github-actions[bot] commented 4 months ago

Hi there! Thanks for opening this issue. We appreciate your contribution to this open-source project. We aim to respond or assign your issue as soon as possible.