mirror of
https://gerrit.wikimedia.org/r/mediawiki/skins/Vector.git
synced 2024-11-28 17:40:12 +00:00
Ensure login button is only rendered for anon users
Bug: T276561 Change-Id: I0f4fa94b4caacc45b299d7518523aa906ff65849
This commit is contained in:
parent
c7ad20524c
commit
22e343eecb
|
@ -242,9 +242,10 @@ class SkinVector extends SkinMustache {
|
|||
$useCombinedLoginLink = $this->useCombinedLoginLink();
|
||||
$htmlCreateAccount = $this->getCreateAccountHTML( $returnto );
|
||||
$userMenuData = $menuData[ 'data-user-menu' ];
|
||||
$userMenuData[ 'html-before-portal' ] = $this->getLoginHTML( $returnto, $useCombinedLoginLink );
|
||||
|
||||
if ( !$isAnon ) {
|
||||
if ( $isAnon ) {
|
||||
$userMenuData[ 'html-before-portal' ] .= $this->getLoginHTML( $returnto, $useCombinedLoginLink );
|
||||
} else {
|
||||
// Appending as to not override data potentially set by the onSkinAfterPortlet hook.
|
||||
$userMenuData[ 'html-after-portal' ] .= $this->getLogoutHTML();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue