* @file
*/
-use MediaWiki\MediaWikiServices;
-
/**
* Query module to perform full text search within wiki titles and content
*
$hasInterwikiResults = false;
$totalhits = null;
if ( $interwiki && $resultPageSet === null && $matches->hasInterwikiResults() ) {
- foreach ( $matches->getInterwikiResults() as $matches ) {
- $matches = $matches->getInterwikiResults();
+ foreach ( $matches->getInterwikiResults() as $interwikiMatches ) {
$hasInterwikiResults = true;
// Include number of results if requested
if ( $resultPageSet === null && isset( $searchInfo['totalhits'] ) ) {
- $totalhits += $matches->getTotalHits();
+ $totalhits += $interwikiMatches->getTotalHits();
}
- $result = $matches->next();
+ $result = $interwikiMatches->next();
while ( $result ) {
$title = $result->getTitle();
$vals = [
'namespace' => $result->getInterwikiNamespaceText(),
'title' => $title->getText(),
- 'url' => $title->getFullUrl(),
+ 'url' => $title->getFullURL(),
];
// Add item to results and see whether it fits
$titles[] = $title;
}
- $result = $matches->next();
+ $result = $interwikiMatches->next();
}
}
if ( $totalhits !== null ) {