From c0e6af209d96aaa121063ee206120f931c7eac6d Mon Sep 17 00:00:00 2001 From: Sam Reed Date: Tue, 12 Oct 2010 22:48:22 +0000 Subject: [PATCH] Remove unused array index, add a couple of braces --- includes/filerepo/FileRepo.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/includes/filerepo/FileRepo.php b/includes/filerepo/FileRepo.php index c65b4038d0..6fd7790025 100644 --- a/includes/filerepo/FileRepo.php +++ b/includes/filerepo/FileRepo.php @@ -163,7 +163,7 @@ abstract class FileRepo { */ function findFiles( $items ) { $result = array(); - foreach ( $items as $index => $item ) { + foreach ( $items as $item ) { if ( is_array( $item ) ) { $title = $item['title']; $options = $item; @@ -173,8 +173,9 @@ abstract class FileRepo { $options = array(); } $file = $this->findFile( $title, $options ); - if ( $file ) + if ( $file ) { $result[$file->getTitle()->getDBkey()] = $file; + } } return $result; } -- 2.20.1