mirror of
https://github.com/arendst/Tasmota.git
synced 2025-04-24 23:07:17 +00:00
Moving test inside timer condition
This commit is contained in:
parent
7a6628d903
commit
6219c0fee2
@ -748,11 +748,11 @@ void wifiKeepAlive(void) {
|
||||
|
||||
if ((WL_CONNECTED != Wifi.status) || (0 == wifiTimerSec)) { return; } // quick exit if wifi not connected or feature disabled
|
||||
|
||||
if (wifiTimerSec > 100) {
|
||||
wifiTimerSec = (wifiTimerSec - 100) * 60; // convert >100 as minutes, ex: 105 = 5 minutes, 110 = 10 minutes
|
||||
}
|
||||
if (TimeReached(wifiTimer)) {
|
||||
stationKeepAliveNow();
|
||||
if (wifiTimerSec > 100) {
|
||||
wifiTimerSec = (wifiTimerSec - 100) * 60; // convert >100 as minutes, ex: 105 = 5 minutes, 110 = 10 minutes
|
||||
}
|
||||
SetNextTimeInterval(wifiTimer, wifiTimerSec * 1000);
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user