fix: examples

This commit is contained in:
Richard Ramos 2020-03-09 15:14:39 -04:00
parent 7160031807
commit 866619dcdc
2 changed files with 2 additions and 4 deletions

View File

@ -30,9 +30,7 @@ const run = async () => {
const resolvers = {
Query: {
myEvents: () => {
return subspace.trackEvent(MyContractInstance, "MyEvent", {filter: {}, fromBlock: 1});
}
myEvents: () => subspace.trackEvent(MyContractInstance, "MyEvent", {filter: {}, fromBlock: 1})
}
};

View File

@ -22,7 +22,7 @@ export default {
created: async function(){
this.MyContractInstance = await MyContract.getInstance();
const subspace = new Subspace(web3.currentProvider);
const subspace = new Subspace(web3);
await subspace.init();
this.myEventObservable$ = subspace.trackEvent(this.MyContractInstance, "MyEvent", {filter: {}, fromBlock: 1 });