$this->error( "Nothing to do.", true );
}
$end = $db->selectField( 'page', 'MAX(page_id)', false, __METHOD__ );
-
+
# Do remaining chunk
$end += $this->mBatchSize - 1;
$blockStart = $start;
// old old format should be treated as edit/move restriction
$oldRestrictions["edit"] = trim( $temp[0] );
$oldRestrictions["move"] = trim( $temp[0] );
- } else if ( $temp[1] ) {
+ } elseif ( $temp[1] ) {
$oldRestrictions[$temp[0]] = trim( $temp[1] );
}
}
}
$blockStart += $this->mBatchSize - 1;
$blockEnd += $this->mBatchSize - 1;
- wfWaitForSlaves( 5 );
+ wfWaitForSlaves();
}
$this->output( "...removing dead rows from page_restrictions\n" );
// Kill any broken rows from previous imports
}
$maintClass = "UpdateRestrictions";
-require_once( DO_MAINTENANCE );
+require_once( RUN_MAINTENANCE_IF_MAIN );