-
Notifications
You must be signed in to change notification settings - Fork 12.3k
Closed
Labels
good first issueLow hanging fruit for new contributors to get involved!Low hanging fruit for new contributors to get involved!
Milestone
Description
Currently BasicToken and StandardToken use internal state variables to track balances, and provides no functions to create balance. Thus, contracts that need to create balance (which is all tokens because by default there will be zero balance) have to manually modify those internal state variables. This is pretty bad UX, and it's breaking encapsulation.
BasicToken's and StandardToken's state variables should be private, and there should be internal functions _mint and _burn that modify them and emit the necessary events.
See ERC721BasicToken for an example:
https://github.com/OpenZeppelin/openzeppelin-solidity/blob/67b67b791ed7a24aa027ea2d17efd5e4d02b4277/contracts/token/ERC721/ERC721BasicToken.sol#L255-L259
nventuro
Metadata
Metadata
Assignees
Labels
good first issueLow hanging fruit for new contributors to get involved!Low hanging fruit for new contributors to get involved!