]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Bug 552476: Remove the obsolete Bugzilla::Flag->has_flags method
authorFrédéric Buclin <LpSolit@gmail.com>
Mon, 29 Mar 2010 21:59:51 +0000 (23:59 +0200)
committerFrédéric Buclin <LpSolit@gmail.com>
Mon, 29 Mar 2010 21:59:51 +0000 (23:59 +0200)
a=LpSolit

Bugzilla.pm
Bugzilla/Flag.pm

index e8a40541211ef2fa5b04d2676e3518e63a264fa7..8bcef7b28045cfa46bef13cc2cd64c543a5f8910 100644 (file)
@@ -536,7 +536,7 @@ sub has_flags {
     my $class = shift;
 
     if (!defined $class->request_cache->{has_flags}) {
-        $class->request_cache->{has_flags} = Bugzilla::Flag::has_flags();
+        $class->request_cache->{has_flags} = Bugzilla::Flag->any_exist;
     }
     return $class->request_cache->{has_flags};
 }
index 59308501a326ed6abd6ad5215a1f883f29162e1b..e6b7bb936dc0f2500345e6eb59757b2f62080615 100644 (file)
@@ -228,26 +228,6 @@ sub bug {
 
 =over
 
-=item C<has_flags>
-
-Returns 1 if at least one flag exists in the DB, else 0. This subroutine
-is mainly used to decide to display the "(My )Requests" link in the footer.
-
-=back
-
-=cut
-
-sub has_flags {
-    my $dbh = Bugzilla->dbh;
-
-    my $has_flags = $dbh->selectrow_array('SELECT 1 FROM flags ' . $dbh->sql_limit(1));
-    return $has_flags || 0;
-}
-
-=pod
-
-=over
-
 =item C<match($criteria)>
 
 Queries the database for flags matching the given criteria