I pushed this contract
https://ropsten.etherscan.io/address/0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2#code
I want to issue test ERC20 token. But when I try to send ETH to my contract I see error.
What I missed?
I pushed this contract
https://ropsten.etherscan.io/address/0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2#code
I want to issue test ERC20 token. But when I try to send ETH to my contract I see error.
What I missed?
This contract doesn't appear to implement a fallback function that accepts ether, so the transaction gets reverted.
If you want your contract to do something when sent ether, implement a payable fallback function:
function() external payable {
// do stuff
}