mirror of
https://github.com/louislam/uptime-kuma.git
synced 2024-11-27 12:00:35 +03:00
fix timeout bypass for upside down push monitor
This commit is contained in:
parent
8abbc9fd15
commit
c690d1c3a1
1 changed files with 1 additions and 1 deletions
|
@ -406,7 +406,7 @@ class Monitor extends BeanModel {
|
|||
|
||||
// If the previous beat was down or pending we use the regular
|
||||
// beatInterval/retryInterval in the setTimeout further below
|
||||
if (previousBeat.status !== UP || msSinceLastBeat > beatInterval * 1000 + bufferTime) {
|
||||
if (previousBeat.status !== (this.isUpsideDown() ? DOWN : UP) || msSinceLastBeat > beatInterval * 1000 + bufferTime) {
|
||||
throw new Error("No heartbeat in the time window");
|
||||
} else {
|
||||
let timeout = beatInterval * 1000 - msSinceLastBeat;
|
||||
|
|
Loading…
Reference in a new issue