]> source.dussan.org Git - nextcloud-server.git/commitdiff
don't throw errors if certificate folder doesn't exist
authorRobin Appelman <icewind@owncloud.com>
Fri, 12 Oct 2012 12:52:22 +0000 (14:52 +0200)
committerRobin Appelman <icewind@owncloud.com>
Fri, 12 Oct 2012 12:52:22 +0000 (14:52 +0200)
apps/files_external/lib/config.php

index f770bfe0756cefaa02a53b31234c89513d1ccd33..0a576f06f1f6884f8e9279fdf4b869f633a7cc8b 100755 (executable)
@@ -109,10 +109,10 @@ class OC_Mount_Config {
                return $personal;
        }
 
-       /**\r
-        * Add directory for mount point to the filesystem\r
-        * @param OC_Fileview instance $view\r
-        * @param string path to mount point\r
+       /**
+        * Add directory for mount point to the filesystem
+        * @param OC_Fileview instance $view
+        * @param string path to mount point
         */
        private static function addMountPointDirectory($view, $path) {
                $dir = '';
@@ -288,6 +288,9 @@ class OC_Mount_Config {
                if (!is_dir($path)) mkdir($path);
                $result = array();
                $handle = opendir($path);
+               if (!$handle) {
+                       return array();
+               }
                while (false !== ($file = readdir($handle))) {
                        if($file != '.' && $file != '..') $result[] = $file;
                }