mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/CategoryTree
synced 2024-11-27 09:43:06 +00:00
Merge "Trigger CategoryTree::setHeaders only if subcategories available"
This commit is contained in:
commit
9399909bf3
|
@ -323,7 +323,6 @@ class Hooks implements
|
|||
public function onCategoryViewer__doCategoryQuery( $type, $res ) {
|
||||
if ( $type === 'subcat' && $res ) {
|
||||
$this->categoryCache->fillFromQuery( $res );
|
||||
CategoryTree::setHeaders( RequestContext::getMain()->getOutput() );
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -354,6 +353,8 @@ class Hooks implements
|
|||
$cat = $this->categoryCache->getCategory( $title );
|
||||
|
||||
$link = $tree->renderNodeInfo( $title, $cat );
|
||||
|
||||
CategoryTree::setHeaders( RequestContext::getMain()->getOutput() );
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue