]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Bug 364286: Code in Classification->products() is suboptimal - Patch by Frédéric...
authorlpsolit%gmail.com <>
Tue, 19 Dec 2006 16:38:49 +0000 (16:38 +0000)
committerlpsolit%gmail.com <>
Tue, 19 Dec 2006 16:38:49 +0000 (16:38 +0000)
Bugzilla/Classification.pm

index 3d264b704dff83e8483fb2349ce2c91c74248174..37ae3a0cca5787e9cd793d441ece740dbc8d34c0 100644 (file)
@@ -106,12 +106,8 @@ sub products {
             SELECT id FROM products
             WHERE classification_id = ?
             ORDER BY name}, undef, $self->id);
-        my @products;
-        foreach my $product_id (@$product_ids) {
-            push (@products, new Bugzilla::Product($product_id));
-        }
-        $self->{'products'} = \@products;
+
+        $self->{'products'} = Bugzilla::Product->new_from_list($product_ids);
     }
     return $self->{'products'};
 }