From 410641ccf4ed887b3988222678704a8c5569002d Mon Sep 17 00:00:00 2001 From: "olav%bkor.dhs.org" <> Date: Tue, 14 Nov 2006 07:32:28 +0000 Subject: Bug 277370: Ability to specify an email address to which notification about all bugs should go Patch by Guillaume Rousse r=bkor a=myk --- editparams.cgi | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'editparams.cgi') diff --git a/editparams.cgi b/editparams.cgi index cbce6405f..80b458d90 100755 --- a/editparams.cgi +++ b/editparams.cgi @@ -32,6 +32,7 @@ use Bugzilla::Config::Common; use Bugzilla::Util; use Bugzilla::Error; use Bugzilla::Token; +use Bugzilla::User; my $user = Bugzilla->login(LOGIN_REQUIRED); my $cgi = Bugzilla->cgi; @@ -116,6 +117,15 @@ if ($action eq 'save' && $current_module) { if ($ok ne "") { ThrowUserError('invalid_parameter', { name => $name, err => $ok }); } + } elsif ($name eq 'globalwatchers') { + # can't check this as others, as Bugzilla::Config::Common + # can not use Bugzilla::User + foreach my $watcher (split(/[,\s]+/, $value)) { + ThrowUserError( + 'invalid_parameter', + { name => $name, err => "no such user $watcher" } + ) unless login_to_id($watcher); + } } push(@changes, $name); SetParam($name, $value); -- cgit v1.2.3-24-g4f1b