Replaced calls to Skin::formatSize() by Language::formatSize() where escaping is...
authorAlexandre Emsenhuber <ialex@users.mediawiki.org>
Fri, 1 Jul 2011 09:03:15 +0000 (09:03 +0000)
committerAlexandre Emsenhuber <ialex@users.mediawiki.org>
Fri, 1 Jul 2011 09:03:15 +0000 (09:03 +0000)
includes/media/Generic.php
includes/specials/SpecialSearch.php

index 0c6de78..2a52683 100644 (file)
@@ -413,10 +413,9 @@ abstract class MediaHandler {
         * @return string
         */
        function getLongDesc( $file ) {
-               global $wgUser;
-               $sk = $wgUser->getSkin();
+               global $wgLang;
                return wfMsgExt( 'file-info', 'parseinline',
-                       $sk->formatSize( $file->getSize() ),
+                       $wgLang->formatSize( $file->getSize() ),
                        $file->getMimeType() );
        }
 
@@ -436,10 +435,9 @@ abstract class MediaHandler {
         * @return string
         */
        static function getGeneralLongDesc( $file ) {
-               global $wgUser;
-               $sk = $wgUser->getSkin();
+               global $wgLang;
                return wfMsgExt( 'file-info', 'parseinline',
-                       $sk->formatSize( $file->getSize() ),
+                       $wgLang->formatSize( $file->getSize() ),
                        $file->getMimeType() );
        }
 
index 2b1ce56..0534abf 100644 (file)
@@ -582,7 +582,7 @@ class SpecialSearch extends SpecialPage {
                $size = wfMsgExt(
                        'search-result-size',
                        array( 'parsemag', 'escape' ),
-                       $this->sk->formatSize( $byteSize ),
+                       $wgLang->formatSize( $byteSize ),
                        $wgLang->formatNum( $wordCount )
                );