Ethereum - Embark console method calls all returning as undefined

116 Views Asked by At

I'm using the Embark framework to build my first DApp, and have been successful in building the "SimpleStorage" Embark demo shown here. I can use the web interface to set and retrieve values successfully, but when I try to do so directly from the Embark console, it returns undefined for any method call to any contract I've deployed.

enter image description here

I've tried using Go-Ethereum as well as EthereumJS TestRPC to no avail.

I also reported the issue here where people seem to have had the same problem but the issue has already been closed by the projects maintainer.

1

There are 1 best solutions below

0
iurimatias On BEST ANSWER

Embark uses web3.js 1.0 , it should be MDBAccount.methods.post("Hello World").send() and MDBService.methods.register().send({gas:900000}) The complete documentation can be found here.