TransferHelper
Functions
safeTransferFrom
Transfers tokens from the targeted address to the given destination Errors with 'STF' if transfer fails
Parameters:
Name | Type | Description |
---|---|---|
| address | The contract address of the token to be transferred |
| address | The originating address from which the tokens will be transferred |
| address | The destination address of the transfer |
| uint256 | The amount to be transferred |
safeTransfer
Transfers tokens from msg.sender to a recipient
Errors with ST if transfer fails
Parameters:
Name | Type | Description |
---|---|---|
| address | The contract address of the token which will be transferred |
| address | The recipient of the transfer |
| uint256 | The value of the transfer |
safeApprove
Approves the stipulated contract to spend the given allowance in the given token
Errors with 'SA' if transfer fails
Parameters:
Name | Type | Description |
---|---|---|
| address | The contract address of the token to be approved |
| address | The target of the approval |
| uint256 | The amount of the given token the target will be allowed to spend |
safeTransferETH
Transfers ETH to the recipient address
Fails with STE
Parameters:
Name | Type | Description |
---|---|---|
| address | The destination of the transfer |
| uint256 | The value to be transferred |
Last updated