From dd8577061f673811fcbd49a17e2cc67d4f5818cb Mon Sep 17 00:00:00 2001 From: Iuri Matias Date: Sun, 15 Dec 2019 17:37:34 -0500 Subject: [PATCH] fix missing context in accounts methods --- remix-lib/src/execution/txRunner.js | 2 +- remix-simulator/src/provider.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/remix-lib/src/execution/txRunner.js b/remix-lib/src/execution/txRunner.js index bc02c30367..ee933e1af2 100644 --- a/remix-lib/src/execution/txRunner.js +++ b/remix-lib/src/execution/txRunner.js @@ -147,7 +147,7 @@ class TxRunner { } runBlockInVm (tx, block, callback) { - this.executionContext.vm().runBlock({ block: block, generate: true, skipBlockValidation: true, skipBalance: false }).then(function (results) { + this.executionContext.vm().runBlock({ block: block, generate: true, skipBlockValidation: true, skipBalance: false }).then((results) => { let result = results.results[0] if (result) { const status = result.execResult.exceptionError ? 0 : 1 diff --git a/remix-simulator/src/provider.js b/remix-simulator/src/provider.js index 64433626a2..c7929e297d 100644 --- a/remix-simulator/src/provider.js +++ b/remix-simulator/src/provider.js @@ -17,7 +17,7 @@ var Provider = function (options) { this.options = options || {} // TODO: init executionContext here this.executionContext = executionContext - this.Accounts = new Accounts() + this.Accounts = new Accounts(this.executionContext) this.Transactions = new Transactions(this.executionContext) this.methods = {}