From 57886ccea2f55e517bd06e7a8f5b90bbf407ab97 Mon Sep 17 00:00:00 2001 From: "lpsolit%gmail.com" <> Date: Mon, 2 Mar 2009 20:23:34 +0000 Subject: [PATCH] =?utf8?q?Bug=20480999:=20Irrelevant=20username=20check=20?= =?utf8?q?in=20the=20'Email=20Addresses,=20Bug=20Numbers,=20and=20Votes'?= =?utf8?q?=20section=20if=20no=20checkbox=20is=20checked=20-=20Patch=20by?= =?utf8?q?=20Fr=C3=83=C2=A9d=C3=83=C2=A9ric=20Buclin=20?= =?utf8?q?=20r/a=3Dmkanat?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- Bugzilla/Search.pm | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) diff --git a/Bugzilla/Search.pm b/Bugzilla/Search.pm index 2f86d2502b..0c0a76562b 100644 --- a/Bugzilla/Search.pm +++ b/Bugzilla/Search.pm @@ -237,15 +237,7 @@ sub init { next; } my $type = $params->param("emailtype$id"); - if ($type eq "exact") { - $type = "anyexact"; - foreach my $name (split(',', $email)) { - $name = trim($name); - if ($name) { - login_to_id($name, THROW_ERROR); - } - } - } + $type = "anyexact" if ($type eq "exact"); my @clist; foreach my $field ("assigned_to", "reporter", "cc", "qa_contact") { @@ -259,6 +251,17 @@ sub init { if (@clist) { push(@specialchart, \@clist); } + else { + # No field is selected. Nothing to see here. + next; + } + + if ($type eq "anyexact") { + foreach my $name (split(',', $email)) { + $name = trim($name); + login_to_id($name, THROW_ERROR) if $name; + } + } } my $chfieldfrom = trim(lc($params->param('chfieldfrom'))) || ''; -- 2.47.3