Priority groups are zero indexed

This commit is contained in:
felixlinker
2020-08-09 19:00:57 +02:00
parent 82142b0cb1
commit ed60a78be0

View File

@@ -117,7 +117,7 @@ export default class PowerManagement extends TranslatedComponent {
return () => {
const prio = m.getPowerPriority();
const newPrio = Math.max(0, prio + delta);
if (0 < newPrio) {
if (0 <= newPrio) {
m.setPowerPriority(newPrio);
}
};