diff options
Diffstat (limited to 'lib/mauve/notifiers/xmpp.rb')
-rw-r--r-- | lib/mauve/notifiers/xmpp.rb | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/lib/mauve/notifiers/xmpp.rb b/lib/mauve/notifiers/xmpp.rb index fa1751c..8254494 100644 --- a/lib/mauve/notifiers/xmpp.rb +++ b/lib/mauve/notifiers/xmpp.rb @@ -150,12 +150,7 @@ module Mauve unless ex.nil? or @closing logger.warn(["Caught",ex.class,ex.to_s,"during XMPP",where].join(" ")) logger.debug ex.backtrace.join("\n") - @closing = true - connect - @mucs.each do |jid, muc| - @mucs.delete(jid) - join_muc(muc[:jid], muc[:password]) - end + self.close end end rescue StandardError => ex @@ -566,11 +561,11 @@ EOF def do_parse_ack(msg) return "Sorry -- I don't understand your acknowledge command." unless - msg.body =~ /ack(?:nowledge)?\s+([\d,]+)\s+for\s+(\d+(?:\.\d+)?)\s+(work(?:ing)?|day(?:time)?|wall(?:-?clock)?)?\s*(day|hour|min(?:ute)?|sec(?:ond))s?(?:\s+because\s+(.*))?/i + msg.body =~ /ack(?:nowledge)?\s+([\d\D]+)\s+for\s+(\d+(?:\.\d+)?)\s+(work(?:ing)?|day(?:time)?|wall(?:-?clock)?)?\s*(day|hour|min(?:ute)?|sec(?:ond))s?(?:\s+because\s+(.*))?/i alerts, n_hours, type_hours, dhms, note = [$1,$2, $3, $4, $5] - alerts = alerts.split(",") + alerts = alerts.split(/\D/) n_hours = case dhms when /^day/ |