Skip to content

Token flow

Jared Pereira requested to merge tokenFlow into master

Add a transferBalance function that performs the checks for valid transferring of amounts.

Use that in a takeBalance function that allows concepts and assessments to take the balance from an address and transfer it to themselves.

Use that function to replace subtractBalance and then just use transfer to replace addBalance.


This essentially ensures that no tokens are being created randomly, and is generally cleaner. Later we will have to implement a mintTokens function to enable inflation.

Merge request reports