r76796 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r76795‎ | r76796 | r76797 >
Date:14:23, 16 November 2010
Author:catrope
Status:ok
Tags:
Comment:
Followup r76782: is_a() -> instanceof (we dropped PHP 4 support over 3 years ago), or -> ||
Modified paths:
  • /trunk/phase3/includes/specials/SpecialUploadStash.php (modified) (history)
  • /trunk/phase3/includes/upload/UploadBase.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/upload/UploadBase.php
@@ -1213,13 +1213,13 @@
12141214 $file = $this->getLocalFile();
12151215 // TODO This cries out for refactoring. We really want to say $file->getAllInfo(); here.
12161216 // Perhaps "info" methods should be moved into files, and the API should just wrap them in queries.
1217 - if ( is_a( $file, 'UploadStashFile' ) ) {
 1217+ if ( $file instanceof UploadStashFile ) {
12181218 $imParam = ApiQueryStashImageInfo::getPropertyNames();
12191219 $info = ApiQueryStashImageInfo::getInfo( $file, array_flip( $imParam ), $result );
12201220 } else {
12211221 $imParam = ApiQueryImageInfo::getPropertyNames();
12221222 $info = ApiQueryImageInfo::getInfo( $file, array_flip( $imParam ), $result );
1223 - }
 1223+ }
12241224 return $info;
12251225 }
12261226
Index: trunk/phase3/includes/specials/SpecialUploadStash.php
@@ -60,7 +60,7 @@
6161 $code = 500;
6262 $message = 'Unknown error';
6363
64 - if ( !isset( $subPage ) or $subPage === '' ) {
 64+ if ( !isset( $subPage ) || $subPage === '' ) {
6565 // the user probably visited the page just to see what would happen, so explain it a bit.
6666 $code = '400';
6767 $message = "Missing key\n\n"

Follow-up revisions

RevisionCommit summaryAuthorDate
r76797uploadwizard-deployment: Merge recent revs from trunk: r75995, r76354, r76386...catrope14:47, 16 November 2010

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r76782Fixed bug#25784 (thumbnails of stashed files had wrong description URLs). ...neilk06:57, 16 November 2010

Status & tagging log