alarms: not self
This commit is contained in:
parent
93c4727324
commit
494286038b
1 changed files with 1 additions and 1 deletions
|
@ -46,7 +46,7 @@ class Alarm(db.Model): # type: ignore
|
|||
if self.alarm_state != state or self.state_changed is None:
|
||||
self.state_changed = datetime.utcnow()
|
||||
activity = Activity(activity_type="alarm_state",
|
||||
text=f"[{self.aspect}] {self.state.emoji} Alarm state changed from "
|
||||
text=f"[{self.aspect}] {state.emoji} Alarm state changed from "
|
||||
f"{self.alarm_state.name} to {state.name} on {self.target}: {text}.")
|
||||
if (self.alarm_state.name in ["WARNING", "CRITICAL"]
|
||||
or state.name in ["WARNING", "CRITICAL"]):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue