Merge pull request #333 from kaosdynamics/patch-1
Wrong hashrate calculation
This commit is contained in:
commit
b955c0cc51
@ -274,9 +274,9 @@ module.exports = function(logger, portalConfig, poolConfigs){
|
|||||||
var i = -1;
|
var i = -1;
|
||||||
var byteUnits = [ ' KH', ' MH', ' GH', ' TH', ' PH' ];
|
var byteUnits = [ ' KH', ' MH', ' GH', ' TH', ' PH' ];
|
||||||
do {
|
do {
|
||||||
hashrate = hashrate / 1024;
|
hashrate = hashrate / 1000;
|
||||||
i++;
|
i++;
|
||||||
} while (hashrate > 1024);
|
} while (hashrate > 1000);
|
||||||
return hashrate.toFixed(2) + byteUnits[i];
|
return hashrate.toFixed(2) + byteUnits[i];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user