Skip to content

Commit

Permalink
Bug 1005780 - When cloning a bug, also add the assignee and qa contac…
Browse files Browse the repository at this point in the history
…t to the CC: list of the new bug

r=glob, a=glob
  • Loading branch information
Simon Green committed May 6, 2014
1 parent b0df54c commit 85e0d6c
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions enter_bug.cgi
Expand Up @@ -216,10 +216,14 @@ if ($cloned_bug_id) {
} else {
$vars->{'cc'} = formvalue('cc');
}

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'});

foreach my $role (qw(reporter assigned_to qa_contact)) {
if (defined($cloned_bug->$role)
&& $cloned_bug->$role->id != $user->id
&& none { $_ eq $cloned_bug->$role->login } @{$cloned_bug->cc})
{
$vars->{'cc'} = join (", ", $cloned_bug->$role->login, $vars->{'cc'});
}
}

foreach my $field (@enter_bug_fields) {
Expand Down

0 comments on commit 85e0d6c

Please sign in to comment.