Browse Source

fix(monitor): safely get status of previous beat if first beat

pull/720/head
Bert Verhelst 3 years ago
parent
commit
1d63dd9ddd
  1. 2
      server/model/monitor.js

2
server/model/monitor.js

@ -304,7 +304,7 @@ class Monitor extends BeanModel {
let beatInterval = this.interval; let beatInterval = this.interval;
let isImportant = Monitor.isImportantBeat(isFirstBeat, previousBeat.status, bean.status); let isImportant = Monitor.isImportantBeat(isFirstBeat, previousBeat?.status, bean.status);
// Mark as important if status changed, ignore pending pings, // Mark as important if status changed, ignore pending pings,
// Don't notify if disrupted changes to up // Don't notify if disrupted changes to up

Loading…
Cancel
Save