Skip to content

Commit

Permalink
Merge pull request #2972 from freenas/NAS-101588-11.3
Browse files Browse the repository at this point in the history
NAS-101588 / 11.3 / Respect alert service enabled field (by themylogin)
  • Loading branch information
themylogin committed Apr 30, 2019
2 parents 64b66ac + 0333434 commit 9228784
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/middlewared/middlewared/plugins/alert.py
Expand Up @@ -294,7 +294,8 @@ async def send_alerts(self, job):
for policy_name, policy in self.policies.items():
gone_alerts, new_alerts = policy.receive_alerts(now, self.alerts)

for alert_service_desc in await self.middleware.call("datastore.query", "system.alertservice"):
for alert_service_desc in await self.middleware.call("datastore.query", "system.alertservice",
[["enabled", "=", True]]):
service_gone_alerts = [
alert for alert in gone_alerts
if (
Expand Down

0 comments on commit 9228784

Please sign in to comment.