From 58cfa7b96dd3e480140b258b9dd88b65b772b0a2 Mon Sep 17 00:00:00 2001 From: Reed Loden Date: Mon, 23 Jul 2012 09:05:05 -0700 Subject: Bug 715432 - Cloned bugs will include duplicates in the CC list if the reporter is also CC'd to the bug [r=glob a=LpSolit] --- enter_bug.cgi | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'enter_bug.cgi') diff --git a/enter_bug.cgi b/enter_bug.cgi index d082bf6a7..b571f8f44 100755 --- a/enter_bug.cgi +++ b/enter_bug.cgi @@ -35,6 +35,8 @@ use Bugzilla::Field; use Bugzilla::Status; use Bugzilla::UserAgent; +use List::MoreUtils qw(none); + my $user = Bugzilla->login(LOGIN_REQUIRED); my $cloned_bug; @@ -231,7 +233,8 @@ if ($cloned_bug_id) { $vars->{'cc'} = formvalue('cc'); } - if ($cloned_bug->reporter->id != $user->id) { + if ($cloned_bug->reporter->id != $user->id + && none { $_ eq $cloned_bug->reporter->login } @{$cloned_bug->cc}) { $vars->{'cc'} = join (", ", $cloned_bug->reporter->login, $vars->{'cc'}); } -- cgit v1.2.3-24-g4f1b