Remove MimeMagic depedency from FSFile and move it to /libs
[lhc/web/wiklou.git] / includes / filerepo / FileRepo.php
index b5c5bf3..1a6c818 100644 (file)
@@ -1540,11 +1540,11 @@ class FileRepo {
         */
        public function getFileProps( $virtualUrl ) {
                $fsFile = $this->getLocalReference( $virtualUrl );
+               $mwProps = new MWFileProps( MimeMagic::singleton() );
                if ( $fsFile ) {
-                       $mwProps = new MWFileProps( MimeMagic::singleton() );
                        $props = $mwProps->getPropsFromPath( $fsFile->getPath(), true );
                } else {
-                       $props = FSFile::placeholderProps();
+                       $props = $mwProps->newPlaceholderProps();
                }
 
                return $props;