Fix alert bug when key missing (#16281)

This commit is contained in:
Tony Murray
2024-08-12 12:21:14 -05:00
committed by GitHub
parent c2770c6f19
commit 9455173edc
+1 -1
View File
@@ -432,7 +432,7 @@ class RunAlerts
} }
} }
if (in_array($alert['state'], [AlertState::ACTIVE, AlertState::WORSE, AlertState::BETTER]) && ! empty($rextra['count']) && ($rextra['count'] == -1 || $alert['details']['count']++ < $rextra['count'])) { if (in_array($alert['state'], [AlertState::ACTIVE, AlertState::WORSE, AlertState::BETTER]) && ! empty($rextra['count']) && isset($alert['details']['count']) && ($rextra['count'] == -1 || $alert['details']['count']++ < $rextra['count'])) {
if ($alert['details']['count'] < $rextra['count']) { if ($alert['details']['count'] < $rextra['count']) {
$noacc = true; $noacc = true;
} }