* (bug 6603) When warning about invalid file extensions, output the bit of the extens...
authorRob Church <robchurch@users.mediawiki.org>
Thu, 21 Dec 2006 17:08:00 +0000 (17:08 +0000)
committerRob Church <robchurch@users.mediawiki.org>
Thu, 21 Dec 2006 17:08:00 +0000 (17:08 +0000)
(The extension extraction code could do with some more improvement)

RELEASE-NOTES
includes/SpecialUpload.php

index 50b04e1..e2860b9 100644 (file)
@@ -365,6 +365,8 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN
   one.
 * (bug 8335) Set image width to the first valid parameter found.
 * (bug 8350) Fix watchlist viewing bug when using Postgres.
+* (bug 6603) When warning about invalid file extensions, output the bit
+  of the extension we actually checked
 
 == Languages updated ==
 
index daa50b3..011cfa6 100644 (file)
@@ -353,7 +353,7 @@ class UploadForm {
                if( $this->checkFileExtensionList( $ext, $wgFileBlacklist ) ||
                        ($wgStrictFileExtensions &&
                                !$this->checkFileExtension( $finalExt, $wgFileExtensions ) ) ) {
-                       return $this->uploadError( wfMsgHtml( 'badfiletype', htmlspecialchars( $fullExt ) ) );
+                       return $this->uploadError( wfMsgHtml( 'badfiletype', htmlspecialchars( $finalExt ) ) );
                }
 
                /**
@@ -396,7 +396,7 @@ class UploadForm {
                        global $wgCheckFileExtensions;
                        if ( $wgCheckFileExtensions ) {
                                if ( ! $this->checkFileExtension( $finalExt, $wgFileExtensions ) ) {
-                                       $warning .= '<li>'.wfMsgHtml( 'badfiletype', htmlspecialchars( $fullExt ) ).'</li>';
+                                       $warning .= '<li>'.wfMsgHtml( 'badfiletype', htmlspecialchars( $finalExt ) ).'</li>';
                                }
                        }