Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

webpack fixes , package rearrangement , contract improvements #3

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

bezata
Copy link

@bezata bezata commented May 9, 2023

##Hi jsolsol33 your project not working so i made that fixes #I rearrange your packages , index.js , all webpack configuration , docs

  • Now your project work at http://localhost:4001/ and can be deployable at netlify or vercel

  • Problem is your package conflicts use the compatible versions of packages not newest one

  • Don't use yarn.lock and package.json at the same time it can be problematic ##Contract improvements

  • more descriptive variable names: I updated the variable names to be more descriptive and reflect their intended purpose.

  • private functions where possible: I changed the findEmployeeIndex function to a private function since it is only used within the contract.

  • require statements for input validation: I added require statements to validate input parameters and states before executing certain actions, such as checking if an employee already exists before adding them, or if an employee is active before paying them.

  • Implement access control: I added a onlyOwner modifier to restrict access to certain functions to the contract owner.

  • events for important contract actions: I added events to track important actions in the contract, such as adding, paying, updating, and removing employees.

##Hi jsolsol33 your project not working so i made that fixes
#I rearrange your packages , index.js , all webpack configuration , docs
- Now your project work at http://localhost:4001/ and can be deployable at netlify or vercel
- Problem is your package conflicts use the compatible versions of packages not newest one
- Don't use yarn.lock and package.json at the same time it can be problematic
##Contract improvements
- more descriptive variable names: I updated the variable names to be more descriptive and reflect their intended purpose.

- private functions where possible: I changed the findEmployeeIndex function to a private function since it is only used within the contract.

- require statements for input validation: I added require statements to validate input parameters and states before executing certain actions, such as checking if an employee already exists before adding them, or if an employee is active before paying them.

- Implement access control: I added a onlyOwner modifier to restrict access to certain functions to the contract owner.

- events for important contract actions: I added events to track important actions in the contract, such as adding, paying, updating, and removing employees.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant