msg( 'unusedcategoriestext' )->parseAsBlock(); } public function getQueryInfo() { return [ 'tables' => [ 'page', 'categorylinks', 'page_props' ], 'fields' => [ 'namespace' => 'page_namespace', 'title' => 'page_title', 'value' => 'page_title' ], 'conds' => [ 'cl_from IS NULL', 'page_namespace' => NS_CATEGORY, 'page_is_redirect' => 0, 'pp_page IS NULL' ], 'join_conds' => [ 'categorylinks' => [ 'LEFT JOIN', 'cl_to = page_title' ], 'page_props' => [ 'LEFT JOIN', [ 'page_id = pp_page', 'pp_propname' => 'expectunusedcategory' ] ] ] ]; } /** * A should come before Z (T32907) * @return bool */ function sortDescending() { return false; } /** * @param Skin $skin * @param object $result Result row * @return string */ function formatResult( $skin, $result ) { $title = Title::makeTitle( NS_CATEGORY, $result->title ); return $this->getLinkRenderer()->makeLink( $title, $title->getText() ); } protected function getGroupName() { return 'maintenance'; } public function preprocessResults( $db, $res ) { $this->executeLBFromResultWrapper( $res ); } }