mirror of
https://github.com/henrygd/beszel.git
synced 2026-03-21 21:26:16 +01:00
fix(hub): check if status alert is triggered before sending up alert (#1806)
This commit is contained in:
@@ -134,7 +134,10 @@ func (am *AlertManager) handleSystemUp(systemName string, alertRecords []*core.R
|
||||
}
|
||||
continue
|
||||
}
|
||||
// No alert scheduled for this record, send "up" alert
|
||||
// No alert scheduled for this record, send "up" alert only if "down" was triggered
|
||||
if !alertRecord.GetBool("triggered") {
|
||||
continue
|
||||
}
|
||||
if err := am.sendStatusAlert("up", systemName, alertRecord); err != nil {
|
||||
am.hub.Logger().Error("Failed to send alert", "err", err)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user