* Remove cruft $time parameter from findFiles()
authorAaron Schulz <aaron@users.mediawiki.org>
Thu, 22 May 2008 15:44:46 +0000 (15:44 +0000)
committerAaron Schulz <aaron@users.mediawiki.org>
Thu, 22 May 2008 15:44:46 +0000 (15:44 +0000)
* Fucking document this fucking function

includes/filerepo/FileRepo.php
includes/filerepo/LocalRepo.php
includes/filerepo/RepoGroup.php

index 2586a11..44ad17d 100644 (file)
@@ -127,9 +127,12 @@ abstract class FileRepo {
        }
        
        /*
-        * Find many files at once
+        * Find many files at once. Removes the corresponding titles
+        * of files that are found from $titles.
+        * @param array $titles, an array of titles
+        * @param int $flags
         */
-       function findFiles( &$titles, $time = false, $flags ) {
+       function findFiles( &$titles, $flags ) {
                $result = array();
                foreach ( $titles as $index => $title ) {
                        $file = $this->findFile( $title );
index 950cf25..0d7fbf0 100644 (file)
@@ -159,7 +159,7 @@ class LocalRepo extends FSRepo {
                return $result;
        }
        
-       function findFiles( &$titles, $time = false, $flags ) {
+       function findFiles( &$titles, $flags ) {
                if ( count( $titles ) == 0 ) return array();            
        
                $dbKeys = array();
index df613a5..938c67f 100644 (file)
@@ -82,15 +82,15 @@ class RepoGroup {
                }
                return false;
        }
-       function findFiles( $titles, $time = false, $flags = 0 ) {
+       function findFiles( $titles, $flags = 0 ) {
                if ( !$this->reposInitialised ) {
                        $this->initialiseRepos();
                }
 
-               $images = $this->localRepo->findFiles( $titles, $time, $flags );
+               $images = $this->localRepo->findFiles( $titles, $flags );
 
                foreach ( $this->foreignRepos as $repo ) {
-                       $images = array_merge( $images, $repo->findFiles( $titles, $time, $flags ) );
+                       $images = array_merge( $images, $repo->findFiles( $titles, $flags ) );
                }
                return $images;
        }