* @ingroup Maintenance
*/
-require_once( __DIR__ . '/Maintenance.php' );
+require_once __DIR__ . '/Maintenance.php';
/**
* Maintenance script that fixes double redirects.
'rd_from = pa.page_id',
'rd_namespace = pb.page_namespace',
'rd_title = pb.page_title',
- '(rd_interwiki IS NULL OR rd_interwiki = "")', // bug 40352
+ 'rd_interwiki IS NULL OR rd_interwiki = ' . $dbr->addQuotes( '' ), // bug 40352
'pb.page_is_redirect' => 1,
);
foreach ( $res as $row ) {
$titleA = Title::makeTitle( $row->pa_namespace, $row->pa_title );
$titleB = Title::makeTitle( $row->pb_namespace, $row->pb_title );
+ RequestContext::getMain()->setTitle( $titleA );
$processedTitles .= "* [[$titleA]]\n";
}
$maintClass = "FixDoubleRedirects";
-require_once( RUN_MAINTENANCE_IF_MAIN );
+require_once RUN_MAINTENANCE_IF_MAIN;