minor fix in extension overview

This commit is contained in:
Dorian Zedler 2020-10-07 13:00:01 +02:00
parent afbbd6b645
commit 2d60e2beeb
Signed by: dorian
GPG key ID: D3B255CB8BC7CD37

View file

@ -164,15 +164,16 @@ ToolBar {
}
function getLaneState(extensions) {
var batteryWarning = false;
for(var i = 0; i < extensions.length; i++) {
console.log(JSON.stringify(extensions[i]))
if(extensions[i]["state"] !== ScStw.ExtensionConnected || extensions[i]["batteryState"] === ScStw.BatteryCritical)
return 2
if(extensions[i]["batteryState"] === ScStw.BatteryWarning)
return 1
batteryWarning = true
}
return 0
return batteryWarning ? 1:0
}
Behavior on border.color {