aboutsummaryrefslogtreecommitdiff
path: root/lib/mauve/configuration_builders
diff options
context:
space:
mode:
authorPatrick J Cherry <patrick@bytemark.co.uk>2012-04-17 11:14:35 +0100
committerPatrick J Cherry <patrick@bytemark.co.uk>2012-04-17 11:14:35 +0100
commitc8d16b7511969edbde58bc49ef44e0ff63e5cb8f (patch)
tree54679f51c429e0cb449581c96edbfd9db07175de /lib/mauve/configuration_builders
parent2cca449f78116aa02072e2e6c5036f63c2ec962b (diff)
* DuringRunner#now? caches its answer, indexed by time. The cache is renewed
on reinitialization. * AlertGroup#notify now initialises and keeps track of each DuringRunner to ensure cache usage.
Diffstat (limited to 'lib/mauve/configuration_builders')
-rw-r--r--lib/mauve/configuration_builders/alert_group.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/mauve/configuration_builders/alert_group.rb b/lib/mauve/configuration_builders/alert_group.rb
index c652de8..56c446d 100644
--- a/lib/mauve/configuration_builders/alert_group.rb
+++ b/lib/mauve/configuration_builders/alert_group.rb
@@ -20,15 +20,15 @@ module Mauve
# @return [Mauve::Notification] New notification instance.
def builder_setup(*who)
who = who.map do |username|
- #raise BuildException.new("You haven't declared who #{username} is") unless
- # @context.people[username]
- #@context.people[username]
if @context.people[username]
@context.people[username]
+
elsif @context.people_lists[username]
@context.people_lists[username]
+
else
raise ArgumentError.new("You have not declared who #{username} is")
+
end
end
@result = Mauve::Notification.new(who, @context.last_alert_group.level)