Follow-up r57091 (revert r56635): rebuild language files
[lhc/web/wiklou.git] / thumb.php
index bb37e6e..6c8dcbf 100644 (file)
--- a/thumb.php
+++ b/thumb.php
@@ -55,14 +55,14 @@ function wfThumbMain() {
                        wfThumbError( 404, wfMsg( 'badtitletext' ) );
                        return;
                }
-               $title = Title::makeTitleSafe( NS_IMAGE, $bits[1] );
+               $title = Title::makeTitleSafe( NS_FILE, $bits[1] );
                if( is_null($title) ) {
                        wfThumbError( 404, wfMsg( 'badtitletext' ) );
                        return;
                }
                $img = RepoGroup::singleton()->getLocalRepo()->newFromArchiveName( $title, $fileName );
        } else {
-               $img = wfLocalFile( $fileName );
+               $img = RepoGroup::singleton()->getLocalRepo()->findFile( $fileName );
        }
 
        if ( !$img ) {