mirror of
https://gerrit.wikimedia.org/r/mediawiki/skins/Vector.git
synced 2024-09-23 18:29:49 +00:00
Merge "Enable table of contents on all namespaces"
This commit is contained in:
commit
530658f160
|
@ -29,9 +29,8 @@ class SkinVector22 extends SkinVector {
|
||||||
private function isTableOfContentsVisibleInSidebar(): bool {
|
private function isTableOfContentsVisibleInSidebar(): bool {
|
||||||
$featureManager = VectorServices::getFeatureManager();
|
$featureManager = VectorServices::getFeatureManager();
|
||||||
$title = $this->getTitle();
|
$title = $this->getTitle();
|
||||||
$isMainNS = $title ? $title->inNamespaces( 0 ) : false;
|
|
||||||
$isMainPage = $title ? $title->isMainPage() : false;
|
$isMainPage = $title ? $title->isMainPage() : false;
|
||||||
return $featureManager->isFeatureEnabled( Constants::FEATURE_TABLE_OF_CONTENTS ) && $isMainNS && !$isMainPage;
|
return $featureManager->isFeatureEnabled( Constants::FEATURE_TABLE_OF_CONTENTS ) && !$isMainPage;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in a new issue