diff options
author | Bjoern Schiessle <schiessle@owncloud.com> | 2012-06-14 15:14:36 +0200 |
---|---|---|
committer | Bjoern Schiessle <schiessle@owncloud.com> | 2012-06-14 15:14:36 +0200 |
commit | 6468e0a1d5f542bccc3c146b56118cb5d1853fc7 (patch) | |
tree | bbdd060df183ae3a396760f8b07d7d704ef81a7d | |
parent | d28a4f0638bf06e9ad84b80fb49c142c4e71f9cd (diff) | |
download | nextcloud-server-6468e0a1d5f542bccc3c146b56118cb5d1853fc7.tar.gz nextcloud-server-6468e0a1d5f542bccc3c146b56118cb5d1853fc7.zip |
fixed bug #996: first picture in folder is repeated in the last position behaving like a directory
-rw-r--r-- | apps/gallery/templates/index.php | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/apps/gallery/templates/index.php b/apps/gallery/templates/index.php index f9926045498..749f8891f81 100644 --- a/apps/gallery/templates/index.php +++ b/apps/gallery/templates/index.php @@ -101,10 +101,8 @@ for($i = 0; $i < count($images); $i++) { $dir_arr = explode('/', $previous_element); -if (count($images)>1) { - if (count($dir_arr)==0) { - $tl->addTile(new \OC\Pictures\TileSingle($previous_element)); - } else if (count($dir_arr) && $ts->getCount() == 0){ +if (count($images)>1 && count($dir_arr) > 1) { + if (count($dir_arr) && $ts->getCount() == 0){ $ts = new \OC\Pictures\TileStack(array($root.$previous_element), $dir_arr[0]); } else { $arr[] = $previous_element; |