Fix lint
Some checks are pending
Lint Test / build (20) (push) Waiting to run
MacOS Build / build (20) (push) Waiting to run
MacOS 12 - x64 DMG Build / build (20) (push) Waiting to run
Ubuntu 22.04 - AppImage Build / build (20) (push) Waiting to run
Ubuntu 22.04 - x64 DEB Build / build (20) (push) Waiting to run
Ubuntu 24.04 - x64 DEB Build / build (20) (push) Waiting to run
Windows Build / build (20) (push) Waiting to run

This commit is contained in:
argenius 2024-11-10 22:28:54 +01:00
parent 0c13fc5bec
commit c4e65f4b8a

View file

@ -111,12 +111,11 @@ export class DaemonStatusService {
if (this.settings.runOnBattery && this._runningOnBattery && this.settings.batteryLevelThreshold > 0) {
const batteryLevel = await this.electronService.getBatteryLevel();
this._batteryTooLow = batteryLevel <= this.settings.batteryLevelThreshold;
console.log(`battery level: ${batteryLevel}, threshold: ${this.settings.batteryLevelThreshold}, too low: ${this._batteryTooLow}`);
}
else if (!this.settings.runOnBattery) {
this._batteryTooLow = false;
}
});
}).then().catch((error: any) => console.error(error));
}
public Dispose(): void {