diff --git a/apps/files_sharing/lib/Controller/RemoteController.php b/apps/files_sharing/lib/Controller/RemoteController.php index f420d695746c3..499c6d9c2e6d7 100644 --- a/apps/files_sharing/lib/Controller/RemoteController.php +++ b/apps/files_sharing/lib/Controller/RemoteController.php @@ -117,6 +117,10 @@ private static function extendShareInfo($share) { $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();