jenkins-bot has submitted this change and it was merged.

Change subject: Regression: bring back the talk icon on article pages in beta
......................................................................


Regression: bring back the talk icon on article pages in beta

Also add missing documentation and fix an outdated comment.

Bug: T122233
Change-Id: Ieb58fa8753346e2ad3404b7fa4279495037f84c7
---
M includes/skins/MinervaTemplateBeta.php
M includes/skins/SkinMinerva.php
M includes/skins/SkinMinervaBeta.php
M resources/skins.minerva.talk/init.js
4 files changed, 8 insertions(+), 5 deletions(-)

Approvals:
  Phuedx: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/includes/skins/MinervaTemplateBeta.php 
b/includes/skins/MinervaTemplateBeta.php
index 5055994..1a3a1a6 100644
--- a/includes/skins/MinervaTemplateBeta.php
+++ b/includes/skins/MinervaTemplateBeta.php
@@ -72,7 +72,7 @@
        protected function getSecondaryActionsHtml() {
                // no secondary actions on the user page
                if ( !$this->getSkin()->isUserPage ) {
-                       parent::getSecondaryActions();
+                       return parent::getSecondaryActionsHtml();
                }
        }
 }
diff --git a/includes/skins/SkinMinerva.php b/includes/skins/SkinMinerva.php
index cbd2ea0..6539231 100644
--- a/includes/skins/SkinMinerva.php
+++ b/includes/skins/SkinMinerva.php
@@ -794,6 +794,7 @@
        /**
         * Returns an array of links for page secondary actions
         * @param BaseTemplate $tpl
+        * @return string[]
         */
        protected function getSecondaryActions( BaseTemplate $tpl ) {
                $buttons = array();
diff --git a/includes/skins/SkinMinervaBeta.php 
b/includes/skins/SkinMinervaBeta.php
index 85b9057..2e9c5b2 100644
--- a/includes/skins/SkinMinervaBeta.php
+++ b/includes/skins/SkinMinervaBeta.php
@@ -79,12 +79,14 @@
        /**
         * Do not return secondary actions on the user page
         *
-        * @inheritdoc
         * @param BaseTemplate $tpl
+        * @return string[]
         */
        protected function getSecondaryActions( BaseTemplate $tpl ) {
-               if ( !$this->isUserPage ) {
-                       parent::getSecondaryActions( $tpl );
+               if ( $this->isUserPage ) {
+                       return array();
+               } else {
+                       return parent::getSecondaryActions( $tpl );
                }
        }
 
diff --git a/resources/skins.minerva.talk/init.js 
b/resources/skins.minerva.talk/init.js
index b0b22da..5475c38 100644
--- a/resources/skins.minerva.talk/init.js
+++ b/resources/skins.minerva.talk/init.js
@@ -45,7 +45,7 @@
 
        init();
 
-       // add an "add discussion" button to talk pages (only for beta and 
logged in users)
+       // add an "add discussion" button to talk pages (only for logged in 
users)
        if (
                !user.isAnon() &&
                ( page.inNamespace( 'talk' ) || page.inNamespace( 'user_talk' ) 
)

-- 
To view, visit https://gerrit.wikimedia.org/r/260707
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ieb58fa8753346e2ad3404b7fa4279495037f84c7
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/MobileFrontend
Gerrit-Branch: master
Gerrit-Owner: Bmansurov <bmansu...@wikimedia.org>
Gerrit-Reviewer: Phuedx <g...@samsmith.io>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to