]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Bug 281596: Remove RelationSet from Bugzilla::Bug
authormkanat%kerio.com <>
Thu, 17 Feb 2005 02:48:59 +0000 (02:48 +0000)
committermkanat%kerio.com <>
Thu, 17 Feb 2005 02:48:59 +0000 (02:48 +0000)
Patch by Max Kanat-Alexander <mkanat@kerio.com> r=LpSolit, a=myk

Bugzilla/Bug.pm

index 380aa6e32dc86fd116ffdf94e97d8c644a99a77f..5e25820e9baae21af3123091733b60269b0c7938 100755 (executable)
@@ -27,7 +27,6 @@ package Bugzilla::Bug;
 
 use strict;
 
-use Bugzilla::RelationSet;
 use vars qw($legal_keywords @legal_platform
             @legal_priority @legal_severity @legal_opsys @legal_bugs_status
             @settable_resolution %components %versions %target_milestone
@@ -201,11 +200,14 @@ sub initBug  {
       $self->{'qa_contact'} = undef;
   }
 
-  my $ccSet = new Bugzilla::RelationSet;
-  $ccSet->mergeFromDB("select who from cc where bug_id=$bug_id");
-  my @cc = $ccSet->toArrayOfStrings();
-  if (@cc) {
-    $self->{'cc'} = \@cc;
+  my $cc_ref = $dbh->selectcol_arrayref(
+      q{SELECT profiles.login_name FROM cc, profiles
+         WHERE bug_id = ?
+           AND cc.who = profiles.userid
+      ORDER BY profiles.login_name},
+      undef, $bug_id);
+  if (scalar(@$cc_ref)) {
+    $self->{'cc'} = $cc_ref;
   }
 
   if (@::legal_keywords) {