Off-by-one error in the json interval calculation.
This commit is contained in:
parent
ebab2c0e11
commit
2abc386895
|
@ -601,7 +601,7 @@ void backgroundTasks(void) {
|
||||||
|
|
||||||
if (Modes.json_path && Modes.json_interval > 0) {
|
if (Modes.json_path && Modes.json_interval > 0) {
|
||||||
time_t now = time(NULL);
|
time_t now = time(NULL);
|
||||||
if (now > next_json) {
|
if (now >= next_json) {
|
||||||
modesWriteJson(Modes.json_path);
|
modesWriteJson(Modes.json_path);
|
||||||
next_json = now + Modes.json_interval;
|
next_json = now + Modes.json_interval;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue