Soeren.oldag has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/208606

Change subject: Fixed some scrutinizer issues.
......................................................................

Fixed some scrutinizer issues.

Change-Id: I981342d7a68e286086fc9ec2d612c0294282534d
---
M includes/Violations/ViolationStore.php
M specials/SpecialCheckResultPage.php
M specials/SpecialWikidataQualityPage.php
3 files changed, 18 insertions(+), 15 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/WikidataQuality 
refs/changes/06/208606/1

diff --git a/includes/Violations/ViolationStore.php 
b/includes/Violations/ViolationStore.php
index 47145e4..60d95bc 100644
--- a/includes/Violations/ViolationStore.php
+++ b/includes/Violations/ViolationStore.php
@@ -66,12 +66,12 @@
                }
        }
 
-       /**
-        * @param Violation $violation
-        *
-        * @return mixed
-        * @throws \DBError
-        */
+    /**
+     * @param string $claimGuid
+     * @param string $constraintClaimGuid
+     * @return bool|\ResultWrapper
+     * @throws \DBUnexpectedError
+     */
        public function removeViolationWith( $claimGuid, $constraintClaimGuid ) 
{
 
                if ( !is_string( $claimGuid ) || !is_string( 
$constraintClaimGuid ) ) {
diff --git a/specials/SpecialCheckResultPage.php 
b/specials/SpecialCheckResultPage.php
index 1bec68f..505ecbe 100644
--- a/specials/SpecialCheckResultPage.php
+++ b/specials/SpecialCheckResultPage.php
@@ -37,7 +37,7 @@
         *
         * @return string
         */
-       protected abstract function getInstructionsText();
+    abstract protected function getInstructionsText();
 
        /**
         * Executes the specific check for the given entity and returns results
@@ -46,14 +46,14 @@
         *
         * @return Traversable
         */
-       protected abstract function executeCheck( Entity $entity );
+    abstract protected function executeCheck( Entity $entity );
 
        /**
         * Returns text that is shown, if result list is empty
         *
         * @return string
         */
-       protected abstract function getEmptyResultText();
+    abstract protected function getEmptyResultText();
 
        /**
         * Builds result table of given results
@@ -63,14 +63,14 @@
         *
         * @return string
         */
-       protected abstract function buildResultTable( EntityId $entityId, 
$results );
+    abstract protected function buildResultTable( EntityId $entityId, $results 
);
 
        /**
         * Returns mapping of specific statuses to generic statuses used in css
         *
         * @return array
         */
-       protected abstract function getStatusMapping();
+    abstract protected function getStatusMapping();
 
        /**
         * @see SpecialPage::execute
diff --git a/specials/SpecialWikidataQualityPage.php 
b/specials/SpecialWikidataQualityPage.php
index 62bbc35..591b14e 100644
--- a/specials/SpecialWikidataQualityPage.php
+++ b/specials/SpecialWikidataQualityPage.php
@@ -4,12 +4,15 @@
 
 use SpecialPage;
 use ValueFormatters\FormatterOptions;
+use ValueFormatters\ValueFormatter;
+use Wikibase\DataModel\Entity\EntityIdParser;
 use Wikibase\Lib\EntityIdLabelFormatter;
 use Wikibase\Lib\EntityIdHtmlLinkFormatter;
 use Wikibase\Lib\EntityIdLinkFormatter;
 use Wikibase\Lib\HtmlUrlFormatter;
 use Wikibase\Lib\LanguageNameLookup;
 use Wikibase\Lib\SnakFormatter;
+use Wikibase\Lib\Store\EntityLookup;
 use Wikibase\Lib\Store\LanguageLabelDescriptionLookup;
 use Wikibase\Repo\WikibaseRepo;
 
@@ -24,17 +27,17 @@
 abstract class SpecialWikidataQualityPage extends SpecialPage {
 
        /**
-        * @var \Wikibase\DataModel\Entity\EntityIdParser
+        * @var EntityIdParser
         */
        protected $entityIdParser;
 
        /**
-        * @var \Wikibase\Lib\Store\EntityLookup
+        * @var EntityLookup
         */
        protected $entityLookup;
 
        /**
-        * @var \ValueFormatters\ValueFormatter
+        * @var ValueFormatter
         */
        protected $dataValueFormatter;
 
@@ -103,7 +106,7 @@
         *
         * @return string
         */
-       function getGroupName() {
+       protected function getGroupName() {
                return 'wikidataquality';
        }
 

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I981342d7a68e286086fc9ec2d612c0294282534d
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/WikidataQuality
Gerrit-Branch: master
Gerrit-Owner: Soeren.oldag <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to