removed unnecessary errors from stats

This commit is contained in:
cubedro 2015-04-16 22:15:42 +03:00
parent 2208ba69ca
commit cccde482f0

View File

@ -81,8 +81,7 @@ function Node()
blockTimes: [],
gasSpending: [],
miners: [],
uptime: 0,
errors: []
uptime: 0
};
this._lastStats = JSON.stringify(this.stats);
@ -141,7 +140,6 @@ function Node()
Node.prototype.isActive = function()
{
this._tries++;
this.stats.errors = [];
try {
var peers = web3.toDecimal(web3.net.peerCount);
@ -155,10 +153,6 @@ Node.prototype.isActive = function()
}
}
catch (err) {
this.stats.errors.push({
code: '1',
msg: err
});
console.error("peerCount:", err);
}
@ -188,10 +182,6 @@ Node.prototype.getBlock = function(number)
return this.stats.block;
}
catch (err) {
this.stats.errors.push({
code: '3',
msg: err
});
console.error("blockNumber:", err);
}
}
@ -205,10 +195,6 @@ Node.prototype.getBlock = function(number)
}
}
catch (err) {
this.stats.errors.push({
code: '2',
msg: err
});
console.error("getBlock:", err);
}