NoSleep: Move evaluation if any peer is still busy to the PeerManager

This commit is contained in:
schlagmichdoch 2024-02-16 15:25:31 +01:00
parent 74bd7dd406
commit 0d17ada58b
2 changed files with 15 additions and 4 deletions

View file

@ -791,7 +791,6 @@ class PeerUI {
this.$el.removeAttribute('status');
this.$el.querySelector('.status').innerHTML = '';
this._currentStatus = null;
NoSleepUI.disableIfIdle();
return;
}
@ -2968,9 +2967,7 @@ class NoSleepUI {
NoSleepUI._active = true;
}
static disableIfIdle() {
if ($$('x-peer[status]')) return;
static disable() {
NoSleepUI._nosleep.disable();
NoSleepUI._active = false;
}