Bug #10228 : don't show 1, when we can show 0. Literally. Yay.
authorDomas Mituzas <midom@users.mediawiki.org>
Mon, 18 Jun 2007 07:37:43 +0000 (07:37 +0000)
committerDomas Mituzas <midom@users.mediawiki.org>
Mon, 18 Jun 2007 07:37:43 +0000 (07:37 +0000)
includes/SpecialStatistics.php

index 1c9e0ab..62e9435 100644 (file)
@@ -24,6 +24,10 @@ function wfSpecialStatistics() {
 
        $admins = $dbr->selectField( 'user_groups', 'COUNT(*)', array( 'ug_group' => 'sysop' ), $fname );
        $numJobs = $dbr->estimateRowCount('job');
+       /* Zero rows still do single row read for row that doesn't exist, but people are annoyed by that */
+       if ($numJobs == 1) {
+               $numJobs = 0;
+       }
 
        if ($action == 'raw') {
                $wgOut->disable();