fixed stats timing

This commit is contained in:
cubedro 2015-05-27 06:46:32 +03:00
parent 7478c6e6c7
commit 24730138e7

View File

@ -406,10 +406,6 @@ Node.prototype.getStats = function(forced)
console.log(' ', 'forced:', chalk.reset.cyan(forced === true)); console.log(' ', 'forced:', chalk.reset.cyan(forced === true));
async.parallel({ async.parallel({
start: function (callback)
{
callback(null, _.now());
},
peers: function (callback) peers: function (callback)
{ {
web3.net.getPeerCount(callback); web3.net.getPeerCount(callback);
@ -444,7 +440,7 @@ Node.prototype.getStats = function(forced)
} }
results.end = _.now(); results.end = _.now();
results.diff = results.end - results.start; results.diff = results.end - self._lastFetch;
console.success('==>', 'Got getStats results in', chalk.reset.cyan(results.diff, 'ms')); console.success('==>', 'Got getStats results in', chalk.reset.cyan(results.diff, 'ms'));