Closed kroggen closed 5 months ago
Tests to be added:
Should work:
TRANSFER
typeShould fail:
TRANSFER
type, contract without function "default"TRANSFER
type, contract function "default" not payableTRANSFER
type, payload not empty (hash)TRANSFER
type, payload not empty (JSON for call)TRANSFER
type, amount = 0
Then repeat the above using NORMAL
type
Should fail:
TRANSFER
type, contract without function "default"TRANSFER
type, contract function "default" not payableTRANSFER
type, payload not empty (hash)The same for NORMAL
type
Should work:
TRANSFER
typeTRANSFER
type, payload not empty (JSON for call)TRANSFER
type, amount = 0
The same for NORMAL
type
@ultrafellen Do you agree with this policy?
These changes are intended to be implemented on hardfork V4:
NORMAL
should not call smart contractsTRANSFER
can only interface with smart contracts on these conditions:amount
must be greater than0
To transfer native Aergo tokens to a smart contract for a function that is not named "default" or that requires arguments, we must use a transaction with type
CALL