From e286e0492a43f2c18938d4de334fded608a569e1 Mon Sep 17 00:00:00 2001 From: Robin Appelman Date: Thu, 18 Aug 2016 16:06:25 +0200 Subject: [PATCH] fix error when not logged in --- apps/files_external/lib/AppInfo/Application.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/apps/files_external/lib/AppInfo/Application.php b/apps/files_external/lib/AppInfo/Application.php index 8e76ffd335..fcf10adb37 100644 --- a/apps/files_external/lib/AppInfo/Application.php +++ b/apps/files_external/lib/AppInfo/Application.php @@ -69,6 +69,10 @@ class Application extends App implements IBackendProvider, IAuthMechanismProvide */ public function registerSettings() { $container = $this->getContainer(); + $userSession = $container->getServer()->getUserSession(); + if (!$userSession->isLoggedIn()) { + return; + } $backendService = $container->query('OCA\\Files_External\\Service\\BackendService'); /** @var \OCA\Files_External\Service\UserGlobalStoragesService $userGlobalStoragesService */