From 18f60768f9cb64ab18a82c9458895e8768d6d563 Mon Sep 17 00:00:00 2001 From: Jonathan Rainville Date: Thu, 28 Jun 2018 10:37:10 -0400 Subject: [PATCH] fix when using mining script --- lib/cmds/blockchain/blockchain.js | 2 +- lib/core/proxy.js | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/cmds/blockchain/blockchain.js b/lib/cmds/blockchain/blockchain.js index a58a2329..31b22e48 100644 --- a/lib/cmds/blockchain/blockchain.js +++ b/lib/cmds/blockchain/blockchain.js @@ -213,7 +213,7 @@ Blockchain.prototype.readyCallback = function() { this.onReadyCallback(); } - if (this.config.mineWhenNeeded) { + if (this.config.mineWhenNeeded && !this.isDev) { const GethMiner = require('./miner'); this.miner = new GethMiner(); } diff --git a/lib/core/proxy.js b/lib/core/proxy.js index 791c6e69..74a40cb3 100644 --- a/lib/core/proxy.js +++ b/lib/core/proxy.js @@ -69,8 +69,8 @@ exports.serve = function(ipc, host, port, ws){ ws: ws }); - proxy.on('error', function () { - console.error(__("Error forwarding requests to blockchain/simulator")); + proxy.on('error', function (e) { + console.error(__("Error forwarding requests to blockchain/simulator"), e); }); proxy.on('proxyRes', (proxyRes) => {