aboutsummaryrefslogtreecommitdiff
path: root/lib/mauve/alert_changed.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/mauve/alert_changed.rb')
-rw-r--r--lib/mauve/alert_changed.rb7
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/mauve/alert_changed.rb b/lib/mauve/alert_changed.rb
index 68a0a00..a07dfa1 100644
--- a/lib/mauve/alert_changed.rb
+++ b/lib/mauve/alert_changed.rb
@@ -82,6 +82,13 @@ module Mauve
# the alert has been acknowledged
#
def remind
+ unless alert.is_a?(Alert)
+ logger.debug "#{self.inspect} lost alert #{alert_id}. Killing self."
+ destroy!
+ return false
+ end
+
+
logger.debug "Reminding someone about #{self.inspect}"
alert_group = AlertGroup.matches(alert)[0]