summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--settings/controller/certificatecontroller.php5
-rw-r--r--settings/personal.php4
2 files changed, 6 insertions, 3 deletions
diff --git a/settings/controller/certificatecontroller.php b/settings/controller/certificatecontroller.php
index 2995c7f38bf..8ff9f51a66c 100644
--- a/settings/controller/certificatecontroller.php
+++ b/settings/controller/certificatecontroller.php
@@ -122,8 +122,9 @@ class CertificateController extends Controller {
protected function isCertificateImportAllowed() {
$externalStorageEnabled = $this->appManager->isEnabledForUser('files_external');
if ($externalStorageEnabled) {
- $backendService = \OC_Mount_Config::$app->getContainer()->query('OCA\Files_External\Service\BackendService');
- if ($backendService->getBackendsVisibleFor(\OCA\Files_External\Service\BackendService::VISIBILITY_PERSONAL)) {
+ /** @var \OCA\Files_External\Service\BackendService $backendService */
+ $backendService = \OC_Mount_Config::$app->getContainer()->query('\OCA\Files_External\Service\BackendService');
+ if ($backendService->isUserMountingAllowed()) {
return true;
}
}
diff --git a/settings/personal.php b/settings/personal.php
index e9e2046f00a..e58e043af50 100644
--- a/settings/personal.php
+++ b/settings/personal.php
@@ -119,7 +119,9 @@ $clients = array(
$enableCertImport = false;
$externalStorageEnabled = \OC::$server->getAppManager()->isEnabledForUser('files_external');
if ($externalStorageEnabled) {
- $enableCertImport = true;
+ /** @var \OCA\Files_External\Service\BackendService $backendService */
+ $backendService = \OC_Mount_Config::$app->getContainer()->query('\OCA\Files_External\Service\BackendService');
+ $enableCertImport = $backendService->isUserMountingAllowed();
}