* @ingroup SpecialPage
*/
+use MediaWiki\MediaWikiServices;
use Wikimedia\Rdbms\IResultWrapper;
use Wikimedia\Rdbms\IDatabase;
use Wikimedia\Rdbms\DBError;
* @param int $offset Paging offset
*/
protected function outputResults( $out, $skin, $dbr, $res, $num, $offset ) {
- global $wgContLang;
-
if ( $num > 0 ) {
$html = [];
if ( !$this->listoutput ) {
# $res might contain the whole 1,000 rows, so we read up to
# $num [should update this to use a Pager]
- // phpcs:ignore Generic.CodeAnalysis.ForLoopWithTestFunctionCall
for ( $i = 0; $i < $num && $row = $res->fetchObject(); $i++ ) {
$line = $this->formatResult( $skin, $row );
if ( $line ) {
}
$html = $this->listoutput
- ? $wgContLang->listToText( $html )
+ ? MediaWikiServices::getInstance()->getContentLanguage()->listToText( $html )
: implode( '', $html );
$out->addHTML( $html );