mirror of
https://github.com/embarklabs/embark.git
synced 2025-02-19 17:14:40 +00:00
fix(@embark/demo): fix ethereum not available in browser in the demo
This only affected the demo. We somehow put the `enableEthereum()` call right before the Demo `set` function, so since we now throw when it's not available, it stopped the `set`. But it was never needed because demo has `autoEnadble` on, meaning that `enable` is called at the start.
This commit is contained in:
parent
a9807b77f5
commit
39919f264c
@ -29,7 +29,6 @@ class Blockchain extends React.Component {
|
|||||||
|
|
||||||
async setValue(e) {
|
async setValue(e) {
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
await EmbarkJS.enableEthereum();
|
|
||||||
var value = parseInt(this.state.valueSet, 10);
|
var value = parseInt(this.state.valueSet, 10);
|
||||||
|
|
||||||
SimpleStorage.methods.set(value).send();
|
SimpleStorage.methods.set(value).send();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user