gluon-status-page: work around js error when printing undefined numbers

This commit is contained in:
Christof 2017-10-25 23:23:56 +02:00 committed by Christof Schulze
parent ad19b82d7c
commit 0606cdf7c2

View File

@ -184,6 +184,10 @@ define(["lib/helper"], function (Helper) {
function prettyPrefix(prefixes, step, d) {
var prefix = 0
if (d == undefined) {
d = 0
}
while (d > step && prefix < prefixes.length - 1) {
d /= step
prefix++