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

Change subject: Declare visibility on class properties of SpecialRevisionDelete
......................................................................


Declare visibility on class properties of SpecialRevisionDelete

All class properties are used solely in the class itself.
SpecialRevisionDelete is not being subclassed, so made all properties
private. Also:
* Added missing class properties.
* Renamed $list to $revDelList to be more specific.
* Updated some documentation.

Change-Id: I9f989a020d46173cb313d4d3dddc33f6b92b1942
---
M includes/specials/SpecialRevisiondelete.php
1 file changed, 40 insertions(+), 34 deletions(-)

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



diff --git a/includes/specials/SpecialRevisiondelete.php 
b/includes/specials/SpecialRevisiondelete.php
index 780da7c..99e6994 100644
--- a/includes/specials/SpecialRevisiondelete.php
+++ b/includes/specials/SpecialRevisiondelete.php
@@ -28,40 +28,46 @@
  * @ingroup SpecialPage
  */
 class SpecialRevisionDelete extends UnlistedSpecialPage {
-       /** True if the submit button was clicked, and the form was posted */
-       var $submitClicked;
-
-       /** Target ID list */
-       var $ids;
-
-       /** Archive name, for reviewing deleted files */
-       var $archiveName;
-
-       /** Edit token for securing image views against XSS */
-       var $token;
-
-       /** Title object for target parameter */
-       var $targetObj;
-
-       /** Deletion type, may be revision, archive, oldimage, filearchive, 
logging. */
-       var $typeName;
-
-       /** Array of checkbox specs (message, name, deletion bits) */
-       var $checks;
-
-       /** UI Labels about the current type */
-       var $typeLabels;
-
-       /** The RevDel_List object, storing the list of items to be 
deleted/undeleted */
-       var $list;
-
-       /** Was the DB modified in this request */
+       /** @var bool Was the DB modified in this request */
        protected $wasSaved = false;
+
+       /** @var bool True if the submit button was clicked, and the form was 
posted */
+       private $submitClicked;
+
+       /** @var array Target ID list */
+       private $ids;
+
+       /** @var string Archive name, for reviewing deleted files */
+       private $archiveName;
+
+       /** @var string Edit token for securing image views against XSS */
+       private $token;
+
+       /** @var Title object for target parameter */
+       private $targetObj;
+
+       /** @var string Deletion type, may be revision, archive, oldimage, 
filearchive, logging. */
+       private $typeName;
+
+       /** @var array of checkbox specs (message, name, deletion bits) */
+       private $checks;
+
+       /** @var array UI Labels about the current type */
+       private $typeLabels;
+
+       /** @var RevDel_List object, storing the list of items to be 
deleted/undeleted */
+       private $revDelList;
+
+       /** @var bool Whether user is allowed to perform the action */
+       private $mIsAllowed;
+
+       /** @var string */
+       private $otherReason;
 
        /**
         * UI labels for each type.
         */
-       static $UILabels = array(
+       private static $UILabels = array(
                'revision' => array(
                        'check-label' => 'revdelete-hide-text',
                        'success' => 'revdelete-success',
@@ -325,13 +331,13 @@
         * Get the list object for this request
         */
        protected function getList() {
-               if ( is_null( $this->list ) ) {
-                       $this->list = RevisionDeleter::createList(
+               if ( is_null( $this->revDelList ) ) {
+                       $this->revDelList = RevisionDeleter::createList(
                                $this->typeName, $this->getContext(), 
$this->targetObj, $this->ids
                        );
                }
 
-               return $this->list;
+               return $this->revDelList;
        }
 
        /**
@@ -552,7 +558,7 @@
                $this->getOutput()->setPageTitle( $this->msg( 'actioncomplete' 
) );
                $this->getOutput()->wrapWikiMsg( "<span 
class=\"success\">\n$1\n</span>", $this->typeLabels['success'] );
                $this->wasSaved = true;
-               $this->list->reloadFromMaster();
+               $this->revDelList->reloadFromMaster();
                $this->showForm();
        }
 
@@ -592,7 +598,7 @@
         * @param $bitfield
         * @param $reason
         * @param $title
-        * @return
+        * @return Status
         */
        protected function save( $bitfield, $reason, $title ) {
                return $this->getList()->setVisibility(

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I9f989a020d46173cb313d4d3dddc33f6b92b1942
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Siebrand <[email protected]>
Gerrit-Reviewer: Chad <[email protected]>
Gerrit-Reviewer: jenkins-bot <>

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

Reply via email to