WMDE-leszek has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/357575 )

Change subject: Update documentation of badge data structure in 
SidebarLinkBadgeDisplay
......................................................................

Update documentation of badge data structure in SidebarLinkBadgeDisplay

Badge item's label is stored under 'label' key not 'itemtitle'.

Change-Id: Ie29afc2e1f1d29c3a3df5e9d5968214a9d671fb1
---
M client/includes/Hooks/SidebarLinkBadgeDisplay.php
1 file changed, 3 insertions(+), 4 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikibase 
refs/changes/75/357575/1

diff --git a/client/includes/Hooks/SidebarLinkBadgeDisplay.php 
b/client/includes/Hooks/SidebarLinkBadgeDisplay.php
index 0717448..b4094ba 100644
--- a/client/includes/Hooks/SidebarLinkBadgeDisplay.php
+++ b/client/includes/Hooks/SidebarLinkBadgeDisplay.php
@@ -7,7 +7,6 @@
 use Wikibase\DataModel\Entity\ItemId;
 use Wikibase\DataModel\Services\Lookup\LabelDescriptionLookup;
 use Wikibase\DataModel\Services\Lookup\LabelDescriptionLookupException;
-use Wikibase\Lib\Store\EntityLookup;
 
 /**
  * Basic display logic to output badges in the sidebar
@@ -53,7 +52,7 @@
         * This is generally called in the context of generating skin output.
         *
         * @param string[] &$sidebarLink
-        * @param string[] $badgeInfo An associative array with the keys 
'class' and 'itemtitle' with assigned
+        * @param string[] $badgeInfo An associative array with the keys 
'class' and 'label' with assigned
         * string values. These fields are the one outputted by the 
getBadgeInfo() function.
         */
        public function applyBadgeToLink( array &$sidebarLink, array $badgeInfo 
) {
@@ -85,9 +84,9 @@
         *
         * @param ItemId[] $badgeIds
         *
-        * @return string[] An associative array with the keys 'class' and 
'itemtitle' with assigned
+        * @return string[] An associative array with the keys 'class' and 
'label' with assigned
         * string values. These fields correspond to the fields in the 
description array for language
-        * links used by the SkinTemplateGetLanguageLink hook and expected by 
the applyBadges()
+        * links used by the SkinTemplateGetLanguageLink hook and expected by 
the applyBadgeToLink()
         * function.
         */
        public function getBadgeInfo( array $badgeIds ) {

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie29afc2e1f1d29c3a3df5e9d5968214a9d671fb1
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Wikibase
Gerrit-Branch: master
Gerrit-Owner: WMDE-leszek <leszek.mani...@wikimedia.de>

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

Reply via email to