public function __construct() {
parent::__construct();
- $this->mDescription = "Script to remove broken, unparseable titles in the Watchlist";
+ $this->addDescription( 'Script to remove broken, unparseable titles in the Watchlist' );
$this->addOption( 'fix', 'Actually remove entries; without will only report.' );
}
private function removeWatch( $row ) {
if ( !$this->dryrun && $this->hasOption( 'fix' ) ) {
- $dbw = wfGetDB( DB_MASTER );
+ $dbw = $this->getDB( DB_MASTER );
$dbw->delete(
'watchlist', array(
'wl_user' => $row->wl_user,