*/
$wgPageLanguageUseDB = false;
-/**
- * Enable use of the *_namespace fields of the pagelinks, redirect, and templatelinks tables.
- * Set this only if the fields are fully populated. This may be removed in 1.25.
- * @var bool
- * @since 1.24
- */
-$wgUseLinkNamespaceDBFields = true;
-
/**
* Global configuration variable for Virtual REST Services.
* Parameters for different services are to be declared inside
'il_to' => $target->getDBkey(),
);
- $useLinkNamespaceDBFields = $this->getConfig()->get( 'UseLinkNamespaceDBFields' );
$namespace = $this->opts->getValue( 'namespace' );
$invert = $this->opts->getValue( 'invert' );
$nsComparison = ( $invert ? '!= ' : '= ' ) . $dbr->addQuotes( $namespace );
if ( is_int( $namespace ) ) {
- if ( $useLinkNamespaceDBFields ) {
- $conds['pagelinks'][] = "pl_from_namespace $nsComparison";
- $conds['templatelinks'][] = "tl_from_namespace $nsComparison";
- $conds['imagelinks'][] = "il_from_namespace $nsComparison";
- } else {
- $conds['pagelinks'][] = "page_namespace $nsComparison";
- $conds['templatelinks'][] = "page_namespace $nsComparison";
- $conds['imagelinks'][] = "page_namespace $nsComparison";
- }
+ $conds['pagelinks'][] = "pl_from_namespace $nsComparison";
+ $conds['templatelinks'][] = "tl_from_namespace $nsComparison";
+ $conds['imagelinks'][] = "il_from_namespace $nsComparison";
}
if ( $from ) {
}
$queryFunc = function ( IDatabase $dbr, $table, $fromCol ) use (
- $conds, $target, $limit, $useLinkNamespaceDBFields
+ $conds, $target, $limit
) {
// Read an extra row as an at-end check
$queryLimit = $limit + 1;
'rd_title' => $target->getDBkey(),
'rd_interwiki = ' . $dbr->addQuotes( '' ) . ' OR rd_interwiki IS NULL'
);
- if ( $useLinkNamespaceDBFields ) { // migration check
- $on['rd_namespace'] = $target->getNamespace();
- }
+ $on['rd_namespace'] = $target->getNamespace();
// Inner LIMIT is 2X in case of stale backlinks with wrong namespaces
$subQuery = $dbr->selectSqlText(
array( $table, 'redirect', 'page' ),