diff options
author | lpsolit%gmail.com <> | 2005-10-27 01:31:16 +0200 |
---|---|---|
committer | lpsolit%gmail.com <> | 2005-10-27 01:31:16 +0200 |
commit | ffc1b98a7703fc60c757cfe12ae1039047dd2932 (patch) | |
tree | 1a9566c17a2d6d355bf518d1bbde0af788253c34 /Bugzilla | |
parent | f4915acec3dc0f746d068ba5c8019ed58df8bdfe (diff) | |
download | bugzilla-ffc1b98a7703fc60c757cfe12ae1039047dd2932.tar.gz bugzilla-ffc1b98a7703fc60c757cfe12ae1039047dd2932.tar.xz |
Bug 313661: New bug bugmail omits initial CC list - Patch by Olav Vitters <bugzilla-mozilla@bkor.dhs.org> r=LpSolit a=myk
Diffstat (limited to 'Bugzilla')
-rw-r--r-- | Bugzilla/BugMail.pm | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/Bugzilla/BugMail.pm b/Bugzilla/BugMail.pm index 6c2f8591c..360d5462d 100644 --- a/Bugzilla/BugMail.pm +++ b/Bugzilla/BugMail.pm @@ -152,8 +152,21 @@ sub ProcessOneBug { my $reporter = $values{'reporter'}; my @assignees = ($values{'assigned_to'}); my @qa_contacts = ($values{'qa_contact'}); - my @ccs = @{$dbh->selectcol_arrayref("SELECT who - FROM cc WHERE bug_id = $id")}; + + my $cc_users = $dbh->selectall_arrayref( + "SELECT cc.who, profiles.login_name + FROM cc + INNER JOIN profiles + ON cc.who = profiles.userid + WHERE bug_id = ?", + undef, $id); + + my (@ccs, @cc_login_names); + foreach my $cc_user (@$cc_users) { + my ($user_id, $user_login) = @$cc_user; + push (@ccs, $user_id); + push (@cc_login_names, $user_login); + } # Include the people passed in as being in particular roles. # This can include people who used to hold those roles. @@ -179,6 +192,7 @@ sub ProcessOneBug { if ($values{'qa_contact'}) { $values{'qa_contact'} = &::DBID_to_name($values{'qa_contact'}); } + $values{'cc'} = join(', ', @cc_login_names); $values{'estimated_time'} = format_time_decimal($values{'estimated_time'}); if ($values{'deadline'}) { |