mirror of
https://github.com/jwinterm/nodejs-pool.git
synced 2026-12-01 11:43:58 +01:00
Reverting timing change for stats.
This commit is contained in:
@@ -132,7 +132,6 @@ function updateShareStats() {
|
|||||||
if (globalMinerList === false) {
|
if (globalMinerList === false) {
|
||||||
globalMinerList = [];
|
globalMinerList = [];
|
||||||
}
|
}
|
||||||
let globalTimes = [];
|
|
||||||
// pplns: 0, pps: 0, solo: 0, prop: 0, global: 0
|
// pplns: 0, pps: 0, solo: 0, prop: 0, global: 0
|
||||||
['pplns', 'pps', 'solo', 'prop', 'global'].forEach(function (key) {
|
['pplns', 'pps', 'solo', 'prop', 'global'].forEach(function (key) {
|
||||||
let cachedData = global.database.getCache(key + "_stats");
|
let cachedData = global.database.getCache(key + "_stats");
|
||||||
@@ -158,9 +157,6 @@ function updateShareStats() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
cachedData.hashHistory.forEach(function(data){
|
|
||||||
globalTimes.push(data.ts);
|
|
||||||
});
|
|
||||||
} else {
|
} else {
|
||||||
cachedData = {
|
cachedData = {
|
||||||
hash: Math.floor(localStats[key] / 600),
|
hash: Math.floor(localStats[key] / 600),
|
||||||
@@ -191,12 +187,6 @@ function updateShareStats() {
|
|||||||
cachedData.hashHistory.pop();
|
cachedData.hashHistory.pop();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
let hashData = cachedData.hashHistory;
|
|
||||||
hashData.forEach(function(data){
|
|
||||||
if (!globalTimes.hasOwnProperty(data.ts)){
|
|
||||||
cachedData.hashHistory.splice(cachedData.hashHistory.indexOf(data), 1);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
cachedData = {
|
cachedData = {
|
||||||
|
|||||||
Reference in New Issue
Block a user