Merge "mw.Feedback: If the message is posted remotely, link the title correctly"
[lhc/web/wiklou.git] / includes / filerepo / RepoGroup.php
index d47624f..24d1ab2 100644 (file)
@@ -138,7 +138,7 @@ class RepoGroup {
                $dbkey = $title->getDBkey();
                if ( empty( $options['ignoreRedirect'] )
                        && empty( $options['private'] )
-                       && empty( $options['bypassCache'] )
+                       && empty( $options['latest'] )
                ) {
                        $time = isset( $options['time'] ) ? $options['time'] : '';
                        if ( $this->cache->has( $dbkey, $time, 60 ) ) {
@@ -334,7 +334,7 @@ class RepoGroup {
        /**
         * Get the repo instance by its name
         * @param string $name
-        * @return bool
+        * @return FileRepo|bool
         */
        function getRepoByName( $name ) {
                if ( !$this->reposInitialised ) {
@@ -452,7 +452,7 @@ class RepoGroup {
 
                        return $repo->getFileProps( $fileName );
                } else {
-                       $mwProps = new MWFileProps( MimeMagic::singleton() );
+                       $mwProps = new MWFileProps( MediaWiki\MediaWikiServices::getInstance()->getMimeAnalyzer() );
 
                        return $mwProps->getPropsFromPath( $fileName, true );
                }