Skip to content

provider.estimateGas doesn't work with a non-zero value #3475

Answered by ricmoo
dimmil123 asked this question in Q&A
Discussion options

You must be logged in to vote

That probably means the contract method is not payable. If you send ether to a non-payable method, it will revert (a non-=payable function effectively has an implicit require(msg.value == 0); at the top of the method.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by dimmil123
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants