Siebrand has uploaded a new change for review.

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


Change subject: Remove unneeded else{} and return
......................................................................

Remove unneeded else{} and return

Else action was default. Returned the result of a void function.

Change-Id: I9ddf051ded0228dd3dfdfe9312f467d9c57f1716
---
M includes/api/ApiUpload.php
1 file changed, 3 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/34/56934/1

diff --git a/includes/api/ApiUpload.php b/includes/api/ApiUpload.php
index 2dcf392..719032f 100644
--- a/includes/api/ApiUpload.php
+++ b/includes/api/ApiUpload.php
@@ -444,9 +444,9 @@
                $verification = $this->mUpload->verifyUpload();
                if ( $verification['status'] === UploadBase::OK ) {
                        return;
-               } else {
-                       return $this->checkVerification( $verification );
                }
+
+               $this->checkVerification( $verification );
        }
 
        /**
@@ -455,7 +455,7 @@
        protected function checkVerification( array $verification ) {
                global $wgFileExtensions;
 
-               // TODO: Move them to ApiBase's message map
+               // @todo Move them to ApiBase's message map
                switch( $verification['status'] ) {
                        // Recoverable errors
                        case UploadBase::MIN_LENGTH_PARTNAME:

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I9ddf051ded0228dd3dfdfe9312f467d9c57f1716
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Siebrand <siebr...@wikimedia.org>

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

Reply via email to