]> source.dussan.org Git - nextcloud-server.git/commitdiff
Don't break when one remote share is down 19886/head
authorJoas Schilling <coding@schilljs.com>
Mon, 9 Mar 2020 16:00:31 +0000 (17:00 +0100)
committerbackportbot[bot] <backportbot[bot]@users.noreply.github.com>
Wed, 11 Mar 2020 08:38:14 +0000 (08:38 +0000)
getFileInfo can also return false

Signed-off-by: Joas Schilling <coding@schilljs.com>
apps/files_sharing/lib/Controller/RemoteController.php

index f420d695746c368b34fea57006b005a8296c1719..499c6d9c2e6d7c122bf4318ddd9e35645ed340ea 100644 (file)
@@ -117,6 +117,10 @@ class RemoteController extends OCSController {
                $view = new \OC\Files\View('/' . \OC_User::getUser() . '/files/');
                $info = $view->getFileInfo($share['mountpoint']);
 
+               if ($info === false) {
+                       return $share;
+               }
+
                $share['mimetype'] = $info->getMimetype();
                $share['mtime'] = $info->getMTime();
                $share['permissions'] = $info->getPermissions();