From: Mark A. Hershberger Date: Wed, 3 Feb 2010 02:19:25 +0000 (+0000) Subject: follow up r61779 - anyone who writes "!$x == null" is an idiot X-Git-Tag: 1.31.0-rc.0~37967 X-Git-Url: https://git.cyclocoop.org/%7B%7B%20url_for%28?a=commitdiff_plain;h=b5e530525b1d00a22deefbed2903cddc04ae2827;p=lhc%2Fweb%2Fwiklou.git follow up r61779 - anyone who writes "!$x == null" is an idiot --- diff --git a/includes/upload/UploadFromChunks.php b/includes/upload/UploadFromChunks.php index 2ecb559f26..c0a8912137 100644 --- a/includes/upload/UploadFromChunks.php +++ b/includes/upload/UploadFromChunks.php @@ -38,7 +38,7 @@ class UploadFromChunks extends UploadBase { } public function initialize( $done, $filename, $sessionKey, $path, - $fileSize, $sessionData ) + $fileSize, $sessionData ) { $this->initFromSessionKey( $sessionKey, $sessionData ); @@ -90,14 +90,14 @@ class UploadFromChunks extends UploadBase { protected function initFromSessionKey( $sessionKey, $sessionData ) { // testing against null because we don't want to cause obscure // bugs when $sessionKey is full of "0" - if ( !$sessionKey === null ) { + if ( $sessionKey !== null ) { $this->status = Status::newFromFatal( 'import-token-mismatch' ); return; } $this->sessionKey = $sessionKey; if ( isset( $sessionData[$this->sessionKey]['version'] ) - && $sessionData[$this->sessionKey]['version'] == self::SESSION_VERSION ) + && $sessionData[$this->sessionKey]['version'] == self::SESSION_VERSION ) { $this->comment = $sessionData[$this->sessionKey]['comment']; $this->pageText = $sessionData[$this->sessionKey]['pageText']; @@ -211,7 +211,7 @@ class UploadFromChunks extends UploadBase { } else { $this->status = Status::newFatal( 'filenotfound', $this->repoPath ); } - if ( $this->fileSize > $wgMaxUploadSize ) + if ( $this->fileSize > $wgMaxUploadSize ) $this->status = Status::newFatal( 'largefileserver' ); }