Commit d10bf9f9 by Torkel Ödegaard

Fixes null checks for legend value formaters (fix for #97)

parent 4152c065
......@@ -55,11 +55,11 @@ function (_, kbn) {
this.info.current = result[result.length-1][1];
var formater = getFormater(yFormats[this.yaxis - 1]);
this.info.avg = formater(this.info.avg);
this.info.current = formater(this.info.current);
this.info.min = formater(this.info.min);
this.info.max = formater(this.info.max);
this.info.total = formater(this.info.total);
this.info.avg = this.info.avg ? formater(this.info.avg) : null;
this.info.current = this.info.current ? formater(this.info.current) : null;
this.info.min = this.info.min ? formater(this.info.min) : null;
this.info.max = this.info.max ? formater(this.info.max) : null;
this.info.total = this.info.total ? formater(this.info.total) : null;
}
return result;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment