42 private $exceptionList =
null;
54 $languageConverterFactory
56 $this->mName =
'Uncategorizedcategories';
66 private function getExceptionList() {
67 if ( $this->exceptionList ===
null ) {
68 $this->exceptionList = [];
69 $exList = $this->
msg(
'uncategorized-categories-exceptionlist' )
70 ->inContentLanguage()->plain();
71 $proposedTitles = explode(
"\n", $exList );
72 foreach ( $proposedTitles as $titleStr ) {
73 if ( !str_starts_with( $titleStr,
'*' ) ) {
76 $titleStr = preg_replace(
"/^\\*\\s*/",
'', $titleStr );
77 $title = Title::newFromText( $titleStr,
NS_CATEGORY );
78 if ( $title && $title->getNamespace() !==
NS_CATEGORY ) {
79 $title = Title::makeTitleSafe(
NS_CATEGORY, $titleStr );
82 $this->exceptionList[] = $title->getDBkey();
86 return $this->exceptionList;
90 $query = parent::getQueryInfo();
91 $exceptionList = $this->getExceptionList();
92 if ( $exceptionList ) {
94 $query[
'conds'][] = $dbr->expr(
'page_title',
'!=', $exceptionList );
107 $title = Title::makeTitle(
NS_CATEGORY, $result->title );
108 $text = $title->getText();