Commit live hack
authorSam Reed <reedy@users.mediawiki.org>
Mon, 1 Aug 2011 23:35:39 +0000 (23:35 +0000)
committerSam Reed <reedy@users.mediawiki.org>
Mon, 1 Aug 2011 23:35:39 +0000 (23:35 +0000)
Commit to trunk also

includes/specials/SpecialUploadStash.php

index eae6265..20a37f0 100644 (file)
@@ -226,8 +226,10 @@ class SpecialUploadStash extends UnlistedSpecialPage {
                $req = MWHttpRequest::factory( $scalerThumbUrl, $httpOptions );
                $status = $req->execute();
                if ( ! $status->isOK() ) {
-                       $errors = $status->getWikiTextArray( $status->getErrorsArray() );
-                       throw new MWException( "Fetching thumbnail failed: " . print_r( $errors, 1 ) );
+                       $errors = $status->getErrorsArray();
+                       $errorStr = "Fetching thumbnail failed: " . print_r( $errors, 1 );
+                       $errorStr .= "\nurl = $scalerThumbUrl\n";
+                       throw new MWException( $errorStr );
                }
                $contentType = $req->getResponseHeader( "content-type" );
                if ( ! $contentType ) {