aboutsummaryrefslogtreecommitdiff
path: root/lib/mauve/notifiers/email.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/mauve/notifiers/email.rb')
-rw-r--r--lib/mauve/notifiers/email.rb9
1 files changed, 4 insertions, 5 deletions
diff --git a/lib/mauve/notifiers/email.rb b/lib/mauve/notifiers/email.rb
index 77b10f1..b6a1e1b 100644
--- a/lib/mauve/notifiers/email.rb
+++ b/lib/mauve/notifiers/email.rb
@@ -35,7 +35,7 @@ module Mauve
end
- def send_alert(destination, alert, all_alerts, conditions = nil)
+ def send_alert(destination, alert, all_alerts, conditions = {})
message = prepare_message(destination, alert, all_alerts, conditions)
args = [@server, @port]
args += [@username, @password, @login_method.to_sym] if @login_method
@@ -54,10 +54,9 @@ module Mauve
protected
- def prepare_message(destination, alert, all_alerts, conditions = nil)
- if conditions
- @suppressed_changed = conditions[:suppressed_changed]
- end
+ def prepare_message(destination, alert, all_alerts, conditions = {})
+ was_suppressed = conditions[:was_suppressed] || false
+ is_suppressed = conditions[:is_suppressed] || false
m = RMail::Message.new