diff --git a/lib/node.js b/lib/node.js index 36792be..b0dbb89 100644 --- a/lib/node.js +++ b/lib/node.js @@ -501,19 +501,21 @@ Node.prototype.getPending = function() { console.info('==>', 'Getting Pending') - web3.eth.getBlockTransactionCount('pending', function (err, results) + web3.eth.getBlockTransactionCount('pending', function (err, pending) { if (err) { console.error('xx>', 'getPending error: ', err); return false; } + var results = {}; results.end = _.now(); results.diff = results.end - now; console.success('==>', 'Got getPending results in', chalk.reset.cyan(results.diff, 'ms')); + console.log(pending); - self.stats.pending = results.pending; + self.stats.pending = pending; self.sendPendingUpdate(); }); @@ -692,12 +694,12 @@ Node.prototype.setWatches = function() if(time > 50) { - self.getStats(true); + self.getPending(true); } else { debounce(function() { - self.getStats(true); + self.getPending(true); }, 50); } });