42 private $exceptionList =
null;
60 $languageConverterFactory
62 $this->mName =
'Uncategorizedcategories';
72 private function getExceptionList() {
73 if ( $this->exceptionList ===
null ) {
74 $this->exceptionList = [];
75 $exList = $this->
msg(
'uncategorized-categories-exceptionlist' )
76 ->inContentLanguage()->plain();
77 $proposedTitles = explode(
"\n", $exList );
78 foreach ( $proposedTitles as $titleStr ) {
79 if ( !str_starts_with( $titleStr,
'*' ) ) {
82 $titleStr = preg_replace(
"/^\\*\\s*/",
'', $titleStr );
83 $title = Title::newFromText( $titleStr,
NS_CATEGORY );
84 if ( $title && $title->getNamespace() !==
NS_CATEGORY ) {
85 $title = Title::makeTitleSafe(
NS_CATEGORY, $titleStr );
88 $this->exceptionList[] = $title->getDBkey();
92 return $this->exceptionList;
96 $query = parent::getQueryInfo();
97 $exceptionList = $this->getExceptionList();
98 if ( $exceptionList ) {
100 $query[
'conds'][] = $dbr->expr(
'page_title',
'!=', $exceptionList );
113 $title = Title::makeTitle(
NS_CATEGORY, $result->title );
114 $text = $title->getText();