$hasErrors = $textStatus && $textStatus->getErrors() !== [];
$hasOtherResults = $textMatches &&
- $textMatches->hasInterwikiResults( SearchResultSet::INLINE_RESULTS );
+ $textMatches->hasInterwikiResults( ISearchResultSet::INLINE_RESULTS );
- if ( $textMatches && $textMatches->hasInterwikiResults( SearchResultSet::SECONDARY_RESULTS ) ) {
+ if ( $textMatches && $textMatches->hasInterwikiResults( ISearchResultSet::SECONDARY_RESULTS ) ) {
$out->addHTML( '<div class="searchresults mw-searchresults-has-iw">' );
} else {
$out->addHTML( '<div class="searchresults">' );
$term, $this->offset, $titleMatches, $textMatches
) );
- if ( $titleMatches ) {
- $titleMatches->free();
- }
-
- if ( $textMatches ) {
- $textMatches->free();
- }
-
$out->addHTML( '<div class="mw-search-visualclear"></div>' );
// prev/next links
$offset = $this->offset;
}
- $prevnext = $this->buildPrevNextNavigation(
+ $prevNext = $this->buildPrevNextNavigation(
$offset,
$this->limit,
$this->powerSearchOptions() + [ 'search' => $term ],
$this->limit + $this->offset >= $totalRes
);
- $out->addHTML( "<p class='mw-search-pager-bottom'>{$prevnext}</p>\n" );
+ $out->addHTML( "<p class='mw-search-pager-bottom'>{$prevNext}</p>\n" );
}
// Close <div class='searchresults'>
/**
* @param Title $title
* @param int $num The number of search results found
- * @param null|SearchResultSet $titleMatches Results from title search
- * @param null|SearchResultSet $textMatches Results from text search
+ * @param null|ISearchResultSet $titleMatches Results from title search
+ * @param null|ISearchResultSet $textMatches Results from text search
*/
protected function showCreateLink( $title, $num, $titleMatches, $textMatches ) {
// show direct page/create link if applicable