summaryrefslogtreecommitdiff
path: root/maintenance/initStats.inc
diff options
context:
space:
mode:
authorPierre Schmitz <pierre@archlinux.de>2009-02-09 23:10:10 +0100
committerPierre Schmitz <pierre@archlinux.de>2009-02-09 23:10:10 +0100
commit4fe7385a8edd62dd7d36fedb157f296e5a57002a (patch)
treed9aef11439d0044d8d8e76ebf3898858bfce789f /maintenance/initStats.inc
parentde5fed526fb1bc218abe51b166691ebc3bd113b6 (diff)
updated to 1.13.4
Diffstat (limited to 'maintenance/initStats.inc')
-rw-r--r--maintenance/initStats.inc22
1 files changed, 11 insertions, 11 deletions
diff --git a/maintenance/initStats.inc b/maintenance/initStats.inc
index d098bc36..b1660ce2 100644
--- a/maintenance/initStats.inc
+++ b/maintenance/initStats.inc
@@ -7,34 +7,34 @@
function wfInitStats( $options=array() ) {
$dbr = wfGetDB( DB_SLAVE );
- echo "Counting total edits...";
+ wfOut( "Counting total edits..." );
$edits = $dbr->selectField( 'revision', 'COUNT(*)', '', __METHOD__ );
$edits += $dbr->selectField( 'archive', 'COUNT(*)', '', __METHOD__ );
- echo "{$edits}\nCounting number of articles...";
+ wfOut( "{$edits}\nCounting number of articles..." );
global $wgContentNamespaces;
$good = $dbr->selectField( 'page', 'COUNT(*)', array( 'page_namespace' => $wgContentNamespaces, 'page_is_redirect' => 0, 'page_len > 0' ), __METHOD__ );
- echo "{$good}\nCounting total pages...";
+ wfOut( "{$good}\nCounting total pages..." );
$pages = $dbr->selectField( 'page', 'COUNT(*)', '', __METHOD__ );
- echo "{$pages}\nCounting number of users...";
+ wfOut( "{$pages}\nCounting number of users..." );
$users = $dbr->selectField( 'user', 'COUNT(*)', '', __METHOD__ );
- echo "{$users}\nCounting number of admins...";
+ wfOut( "{$users}\nCounting number of admins..." );
$admin = $dbr->selectField( 'user_groups', 'COUNT(*)', array( 'ug_group' => 'sysop' ), __METHOD__ );
- echo "{$admin}\nCounting number of images...";
+ wfOut( "{$admin}\nCounting number of images..." );
$image = $dbr->selectField( 'image', 'COUNT(*)', '', __METHOD__ );
- echo "{$image}\n";
+ wfOut( "{$image}\n" );
if( !isset( $options['noviews'] ) ) {
- echo "Counting total page views...";
+ wfOut( "Counting total page views..." );
$views = $dbr->selectField( 'page', 'SUM(page_counter)', '', __METHOD__ );
- echo "{$views}\n";
+ wfOut( "{$views}\n" );
}
- echo "\nUpdating site statistics...";
+ wfOut( "\nUpdating site statistics..." );
$dbw = wfGetDB( DB_MASTER );
$values = array( 'ss_total_edits' => $edits,
@@ -53,5 +53,5 @@ function wfInitStats( $options=array() ) {
$dbw->insert( 'site_stats', array_merge( $values, $conds, $views ), __METHOD__ );
}
- echo( "done.\n" );
+ wfOut( "done.\n" );
}