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

Change subject: Declare class properties, update docs
......................................................................


Declare class properties, update docs

Based on static code analysis.

Change-Id: Ibafe33b6327ab72429ba961079af40039fb41cbf
---
M AbuseFilterVariableHolder.php
M Views/AbuseFilterView.php
M Views/AbuseFilterViewEdit.php
M Views/AbuseFilterViewExamine.php
M Views/AbuseFilterViewRevert.php
M Views/AbuseFilterViewTestBatch.php
M special/SpecialAbuseFilter.php
M special/SpecialAbuseLog.php
8 files changed, 24 insertions(+), 7 deletions(-)

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



diff --git a/AbuseFilterVariableHolder.php b/AbuseFilterVariableHolder.php
index 96aa288..9329494 100644
--- a/AbuseFilterVariableHolder.php
+++ b/AbuseFilterVariableHolder.php
@@ -207,8 +207,8 @@
         * It's like Article::prepareTextForEdit, but not for editing (old 
wikitext usually)
         *
         *
-        * @param $wikitext String
-        * @param $article Article
+        * @param string $wikitext
+        * @param WikiPage $article
         *
         * @return object
         */
@@ -298,7 +298,7 @@
        }
 
        /**
-        * @param $article Article
+        * @param WikiPage $article
         * @return array
         */
        static function getLinksFromDB( $article ) {
diff --git a/Views/AbuseFilterView.php b/Views/AbuseFilterView.php
index db53d6d..56200c2 100644
--- a/Views/AbuseFilterView.php
+++ b/Views/AbuseFilterView.php
@@ -1,8 +1,10 @@
 <?php
 
 abstract class AbuseFilterView extends ContextSource {
+       public $mFilter, $mHistoryID, $mSubmit;
+
        /**
-        * @param $page SpecialPage
+        * @param $page SpecialAbuseFilter
         * @param $params array
         */
        function __construct( $page, $params ) {
diff --git a/Views/AbuseFilterViewEdit.php b/Views/AbuseFilterViewEdit.php
index 42e4e81..3141e93 100644
--- a/Views/AbuseFilterViewEdit.php
+++ b/Views/AbuseFilterViewEdit.php
@@ -2,7 +2,7 @@
 
 class AbuseFilterViewEdit extends AbuseFilterView {
        /**
-        * @param SpecialPage $page
+        * @param SpecialAbuseFilter $page
         * @param array $params
         */
        function __construct( $page, $params ) {
diff --git a/Views/AbuseFilterViewExamine.php b/Views/AbuseFilterViewExamine.php
index f50ab5e..47d4b43 100644
--- a/Views/AbuseFilterViewExamine.php
+++ b/Views/AbuseFilterViewExamine.php
@@ -4,6 +4,9 @@
        public static $examineType = null;
        public static $examineId = null;
 
+       public $mCounter, $mSearchUser, $mSearchPeriodStart, $mSearchPeriodEnd,
+               $mTestFilter;
+
        function show() {
                $out = $this->getOutput();
                $out->setPageTitle( $this->msg( 'abusefilter-examine' ) );
@@ -209,6 +212,10 @@
 }
 
 class AbuseFilterExaminePager extends ReverseChronologicalPager {
+       /**
+        * @param AbuseFilterViewExamine $page
+        * @param AbuseFilterChangesList $changesList
+        */
        function __construct( $page, $changesList ) {
                parent::__construct();
                $this->mChangesList = $changesList;
diff --git a/Views/AbuseFilterViewRevert.php b/Views/AbuseFilterViewRevert.php
index 9d5791e..d926c01 100644
--- a/Views/AbuseFilterViewRevert.php
+++ b/Views/AbuseFilterViewRevert.php
@@ -1,6 +1,9 @@
 <?php
 
 class AbuseFilterViewRevert extends AbuseFilterView {
+       public $origPeriodStart, $origPeriodEnd, $mPeriodStart, $mPeriodEnd,
+               $mReason;
+
        function show() {
                $filter = $this->mPage->mFilter;
 
diff --git a/Views/AbuseFilterViewTestBatch.php 
b/Views/AbuseFilterViewTestBatch.php
index 0d212b2..ecce923 100644
--- a/Views/AbuseFilterViewTestBatch.php
+++ b/Views/AbuseFilterViewTestBatch.php
@@ -4,6 +4,9 @@
        // Hard-coded for now.
        static $mChangeLimit = 100;
 
+       public $mShowNegative, $mTestPeriodStart, $mTestPeriodEnd, $mTestPage,
+               $mTestUser;
+
        function show() {
                $out = $this->getOutput();
 
diff --git a/special/SpecialAbuseFilter.php b/special/SpecialAbuseFilter.php
index 84f7228..2031db5 100644
--- a/special/SpecialAbuseFilter.php
+++ b/special/SpecialAbuseFilter.php
@@ -1,6 +1,8 @@
 <?php
 
 class SpecialAbuseFilter extends SpecialPage {
+       public $mFilter, $mHistoryID;
+
        public function __construct() {
                parent::__construct( 'AbuseFilter', 'abusefilter-view' );
        }
@@ -100,6 +102,7 @@
                // Links at the top
                AbuseFilter::addNavigationLinks( $this->getContext(), $pageType 
);
 
+               /** @var AbuseFilterView $v */
                $v = new $view( $this, $params );
                $v->show();
        }
diff --git a/special/SpecialAbuseLog.php b/special/SpecialAbuseLog.php
index fe45547..aa4ecc8 100644
--- a/special/SpecialAbuseLog.php
+++ b/special/SpecialAbuseLog.php
@@ -590,7 +590,6 @@
 }
 
 class AbuseLogPager extends ReverseChronologicalPager {
-
        /**
         * @var HtmlForm
         */
@@ -602,7 +601,7 @@
        public $mConds;
 
        /**
-        * @param $form
+        * @param SpecialAbuseLog $form
         * @param array $conds
         * @param bool $details
         */

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ibafe33b6327ab72429ba961079af40039fb41cbf
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/AbuseFilter
Gerrit-Branch: master
Gerrit-Owner: Siebrand <[email protected]>
Gerrit-Reviewer: Alex Monk <[email protected]>
Gerrit-Reviewer: Hashar <[email protected]>
Gerrit-Reviewer: jenkins-bot

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

Reply via email to