Partial revert: invalid placeholder
authorAaron Schulz <aaron@users.mediawiki.org>
Sun, 3 Feb 2008 08:10:05 +0000 (08:10 +0000)
committerAaron Schulz <aaron@users.mediawiki.org>
Sun, 3 Feb 2008 08:10:05 +0000 (08:10 +0000)
includes/GlobalFunctions.php
includes/ImagePage.php

index ccf7f84..3b19ae4 100644 (file)
@@ -2280,8 +2280,8 @@ function wfFindFile( $title, $time = false ) {
  * Get an object referring to a locally registered file.
  * Returns a valid placeholder object if the file does not exist.
  */
-function wfLocalFile( $title, $time = false ) {
-       return RepoGroup::singleton()->getLocalRepo()->findFile( $title, $time );
+function wfLocalFile( $title ) {
+       return RepoGroup::singleton()->getLocalRepo()->newFile( $title );
 }
 
 /**
index 02cfc66..84beb56 100644 (file)
@@ -23,7 +23,7 @@ class ImagePage extends Article {
                parent::__construct( $title );
                $this->img = wfFindFile( $this->mTitle, $time );
                if ( !$this->img ) {
-                       $this->img = wfLocalFile( $this->mTitle, $time );
+                       $this->img = wfLocalFile( $this->mTitle );
                }
                $this->repo = $this->img->repo;
        }