Function: transferFrom(address from, address to, uint256 amount)
This allows users to transfer tokens from one address to another, provided that the sender has been approved to spend tokens on behalf of the owner.
Inputs
fromControl: Fully controlled by the caller.
Constraints: None.
Impact: The address to transfer tokens from.
toControl: Fully controlled by the caller.
Constraints: None.
Impact: The address to transfer tokens to.
amountControl: Fully controlled by the caller.
Constraints: None.
Impact: The amount of tokens to transfer.
Branches and code coverage (including function calls)
Intended branches
Assumed
fromposesses enough tokens to transfer.Assumed
fromhas approvedmsg.senderto spend tokens on their behalf.Decrease balance of
fromby amount.Increase balance of
toby amount.
Negative behavior
Should not be callable if
fromdoes not posess enough tokens to transfer.Should not be callable if
fromhas not approvedmsg.senderto spend tokens on their behalf.