From 272f38031430bbe94d74019d9112ac8ba01d9d42 Mon Sep 17 00:00:00 2001 From: Frédéric Buclin Date: Mon, 5 Mar 2012 18:04:28 +0100 Subject: Bug 732978: preload() must load Bugzilla::Component itself r=dkl a=LpSolit --- Bugzilla/Product.pm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Bugzilla/Product.pm b/Bugzilla/Product.pm index bc5c6d926..fdebc6b00 100644 --- a/Bugzilla/Product.pm +++ b/Bugzilla/Product.pm @@ -109,7 +109,8 @@ sub preload { my @prod_ids = keys %prods; return unless @prod_ids; - my $dbh = Bugzilla->dbh; + # We cannot |use| it due to a dependency loop with Bugzilla::User. + require Bugzilla::Component; foreach my $field (qw(component version milestone)) { my $classname = "Bugzilla::" . ucfirst($field); my $objects = $classname->match({ product_id => \@prod_ids }); -- cgit v1.2.3-24-g4f1b