Closed vertangelx closed 5 years ago
This is obviously a security feature of MetaMask. Just imagine if they didn't ask for approval. Some malicious dApp could easily steal all your coins with a simple transaction. If no injected web3 library is detected in the browser, truffle will load a web3 library on its own and by default connect to the localhost. Depending on your local client (e.g. testrpc
), transaction calls will be automatically signed.
What is this transaction, by the way? And where do I find the code that creates this transaction?
Edit: Oh, it's just the gas price for setting the variable. Didn't realize the default type for local variables like uint storedData
is storage
.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
This issue has been closed, but can be re-opened if further comments indicate that the problem persists. Feel free to tag maintainers if no there is no reply to further comments.
I ran the example with Metamask disabled and the stored value is correctly shown as
5
.However when I enable the Metamask plugin in Chrome, the Metamask window appears asking for the transaction to be approved, before the
SimpleStorage
methodset
is called.Can someone please explain why the transaction is automatically approved/signed when Metamask is disabled, but not when Metamask is enabled?