Enable table of contents on all namespaces

Bug: T304168
Change-Id: Ib61f801640e77c34573c166072f0fb302687e8b1
This commit is contained in:
Jon Robson 2022-03-24 08:56:13 -07:00
parent 1b8ee10357
commit 56164a4275

View file

@ -29,9 +29,8 @@ class SkinVector22 extends SkinVector {
private function isTableOfContentsVisibleInSidebar(): bool {
$featureManager = VectorServices::getFeatureManager();
$title = $this->getTitle();
$isMainNS = $title ? $title->inNamespaces( 0 ) : 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;
}
/**