*
* You should have received a copy of the GNU General Public License along
* with this program; if not, write to the Free Software Foundation, Inc.,
- * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
* http://www.gnu.org/copyleft/gpl.html
*
* @author Brion Vibber <brion at pobox.com>
- * @package MediaWiki
- * @subpackage maintenance
+ * @addtogroup maintenance
*/
$options = array( 'fix' );
$estimatedTotalTime = $delta / $portion;
$eta = $this->startTime + $estimatedTotalTime;
- global $wgDBname;
printf( "%s %s: %6.2f%% done on %s; ETA %s [%d/%d] %.2f/sec <%.2f%% updated>\n",
- $wgDBname,
+ wfWikiID(),
wfTimestamp( TS_DB, intval( $now ) ),
$portion * 100.0,
$this->table,
$result = $this->dbr->query( $sql, $fname );
while( $row = $this->dbr->fetchObject( $result ) ) {
- $updated = call_user_func( $callback, $row );
+ call_user_func( $callback, $row );
}
$this->log( "Finished $table... $this->updated of $this->processed rows updated" );
$this->dbr->freeResult( $result );
}
function processEntry( $row ) {
- global $wgContLang;
-
$current = Title::makeTitle( $row->wl_namespace, $row->wl_title );
$display = $current->getPrefixedText();
function removeWatch( $row ) {
if( !$this->dryrun) {
- $dbw =& wfGetDB( DB_MASTER );
+ $dbw = wfGetDB( DB_MASTER );
$dbw->delete( 'watchlist', array(
'wl_user' => $row->wl_user,
'wl_namespace' => $row->wl_namespace,
$caps = new WatchlistCleanup( !isset( $options['fix'] ) );
$caps->cleanup();
-?>
+