diff --git a/apps/files_external/lib/AppInfo/Application.php b/apps/files_external/lib/AppInfo/Application.php index 06c163419f..8e76ffd335 100644 --- a/apps/files_external/lib/AppInfo/Application.php +++ b/apps/files_external/lib/AppInfo/Application.php @@ -68,7 +68,14 @@ class Application extends App implements IBackendProvider, IAuthMechanismProvide * Register settings templates */ public function registerSettings() { - \OCP\App::registerPersonal('files_external', 'personal'); + $container = $this->getContainer(); + $backendService = $container->query('OCA\\Files_External\\Service\\BackendService'); + + /** @var \OCA\Files_External\Service\UserGlobalStoragesService $userGlobalStoragesService */ + $userGlobalStoragesService = $container->query('OCA\Files_External\Service\UserGlobalStoragesService'); + if (count($userGlobalStoragesService->getStorages()) > 0 || $backendService->isUserMountingAllowed()) { + \OCP\App::registerPersonal('files_external', 'personal'); + } } /**