From ca32f08966f1b51fcb19460f0996bb0c4048e6fe Mon Sep 17 00:00:00 2001 From: Pierre Schmitz Date: Sat, 3 Dec 2011 13:29:22 +0100 Subject: Update to MediaWiki 1.18.0 * also update ArchLinux skin to chagnes in MonoBook * Use only css to hide our menu bar when printing --- maintenance/populateLogSearch.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'maintenance/populateLogSearch.php') diff --git a/maintenance/populateLogSearch.php b/maintenance/populateLogSearch.php index ce2d95cc..f13873cb 100644 --- a/maintenance/populateLogSearch.php +++ b/maintenance/populateLogSearch.php @@ -35,7 +35,7 @@ class PopulateLogSearch extends Maintenance { } public function execute() { - $db = wfGetDB( DB_MASTER ); + $db = $this->getDB( DB_MASTER ); if ( !$db->tableExists( 'log_search' ) ) { $this->error( "log_search does not exist", true ); } @@ -97,14 +97,14 @@ class PopulateLogSearch extends Maintenance { foreach ( $sres as $srow ) { if ( $srow->$userField > 0 ) $userIds[] = intval( $srow->$userField ); - else if ( $srow->$userTextField != '' ) + elseif ( $srow->$userTextField != '' ) $userIPs[] = $srow->$userTextField; } // Add item author relations... $log->addRelations( 'target_author_id', $userIds, $row->log_id ); $log->addRelations( 'target_author_ip', $userIPs, $row->log_id ); // RevisionDelete logs - log events - } else if ( LogEventsList::typeAction( $row, $delTypes, 'event' ) ) { + } elseif ( LogEventsList::typeAction( $row, $delTypes, 'event' ) ) { $params = LogPage::extractParams( $row->log_params ); // Param format: [ ] if ( count( $params ) < 1 ) continue; // bad row @@ -121,7 +121,7 @@ class PopulateLogSearch extends Maintenance { foreach ( $sres as $srow ) { if ( $srow->log_user > 0 ) $userIds[] = intval( $srow->log_user ); - else if ( IP::isIPAddress( $srow->log_user_text ) ) + elseif ( IP::isIPAddress( $srow->log_user_text ) ) $userIPs[] = $srow->log_user_text; } $log->addRelations( 'target_author_id', $userIds, $row->log_id ); @@ -130,7 +130,7 @@ class PopulateLogSearch extends Maintenance { } $blockStart += self::LOG_SEARCH_BATCH_SIZE; $blockEnd += self::LOG_SEARCH_BATCH_SIZE; - wfWaitForSlaves( 5 ); + wfWaitForSlaves(); } if ( $db->insert( 'updatelog', -- cgit v1.2.3-54-g00ecf