]> source.dussan.org Git - nextcloud-server.git/commitdiff
make gallary work with archives
authorRobin Appelman <icewind@owncloud.com>
Wed, 7 Mar 2012 15:24:49 +0000 (16:24 +0100)
committerRobin Appelman <icewind@owncloud.com>
Wed, 7 Mar 2012 15:24:49 +0000 (16:24 +0100)
apps/gallery/ajax/galleryOp.php
apps/gallery/lib/scanner.php

index ee919daeacbfbaa95a7555d45735d7e2bbd744db..74ac905d072a6d2c4b688aa0f94da9bfdfb5483a 100644 (file)
@@ -95,7 +95,6 @@ function handleGetGallery($path) {
   else
     $path = '/'.ltrim($path, '/');
   if (strlen($path) > 1) $path = rtrim($path, '/');
-  error_log($path);
   $result = OC_Gallery_Album::find(OC_User::getUser(), null, $path);
   $album_details = $result->fetchRow();
 
index 8dcd77821cb1d4778bf733b4823c7eda9c6acabd..1e8fdb63fb3470a6137662d2717912e6be8d20ac 100644 (file)
@@ -47,7 +47,7 @@ class OC_Gallery_Scanner {
     $current_album = array('name'=> $path, 'imagesCount' => 0, 'images' => array());
     $current_album['name'] = self::createName($current_album['name']);
 
-    if ($dh = OC_Filesystem::opendir($path)) {
+    if ($dh = OC_Filesystem::opendir($path.'/')) {
       while (($filename = readdir($dh)) !== false) {
         $filepath = ($path[strlen($path)-1]=='/'?$path:$path.'/').$filename;
         if (substr($filename, 0, 1) == '.') continue;