mirror of
https://gerrit.wikimedia.org/r/mediawiki/skins/Vector.git
synced 2024-11-28 09:30:17 +00:00
Merge "Don't show language alert on main page if it has no languages"
This commit is contained in:
commit
fa3c528bef
|
@ -558,7 +558,7 @@ class SkinVector extends SkinMustache {
|
|||
private function shouldLanguageAlertBeInSidebar(): bool {
|
||||
$featureManager = VectorServices::getFeatureManager();
|
||||
$isMainPage = $this->getTitle() ? $this->getTitle()->isMainPage() : false;
|
||||
$shouldShowOnMainPage = $isMainPage &&
|
||||
$shouldShowOnMainPage = $isMainPage && !empty( $this->getLanguagesCached() ) &&
|
||||
$featureManager->isFeatureEnabled( Constants::FEATURE_LANGUAGE_IN_MAIN_PAGE_HEADER );
|
||||
return ( $this->isLanguagesInContentAt( 'top' ) && !$isMainPage &&
|
||||
$featureManager->isFeatureEnabled( Constants::FEATURE_LANGUAGE_ALERT_IN_SIDEBAR ) ) ||
|
||||
|
|
Loading…
Reference in a new issue