[BUGFIX] Show available firmware information

This commit is contained in:
Moritz Warning 2017-09-05 23:37:59 +02:00 committed by Xaver Maierhofer
parent 9aff29a634
commit a5d4140bda
No known key found for this signature in database
GPG Key ID: 7FDCE23FD2EC9FE8

View File

@ -27,14 +27,12 @@ define(['sorttable', 'snabbdom', 'd3-interpolate', 'moment', 'helper'],
} }
function showFirmware(d) { function showFirmware(d) {
var release = helper.dictGet(d.nodeinfo, ['software', 'firmware', 'release']); return [
var base = helper.dictGet(d.nodeinfo, ['software', 'firmware', 'base']); helper.dictGet(d.nodeinfo, ['software', 'firmware', 'release']),
helper.dictGet(d.nodeinfo, ['software', 'firmware', 'base'])
if (release === null || base === null) { ].filter(function (n) {
return undefined; return n !== null;
} }).join(' / ') || undefined;
return release + ' / ' + base;
} }
function showSite(d, config) { function showSite(d, config) {