Skip to content

Commit 45f7e26

Browse files
icewind1991backportbot[bot]
authored andcommitted
fix: remove duplicate 'allow creating local storage' check
Signed-off-by: Robin Appelman <robin@icewind.nl>
1 parent 488651a commit 45f7e26

2 files changed

Lines changed: 0 additions & 19 deletions

File tree

apps/files_external/lib/Controller/GlobalStoragesController.php

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -100,16 +100,6 @@ public function create(
100100
$applicableGroups,
101101
$priority
102102
) {
103-
$canCreateNewLocalStorage = $this->config->getSystemValue('files_external_allow_create_new_local', true);
104-
if (!$canCreateNewLocalStorage && $backend === 'local') {
105-
return new DataResponse(
106-
[
107-
'message' => $this->l10n->t('Forbidden to manage local mounts')
108-
],
109-
Http::STATUS_FORBIDDEN
110-
);
111-
}
112-
113103
$newStorage = $this->createStorage(
114104
$mountPoint,
115105
$backend,

apps/files_external/lib/Controller/UserStoragesController.php

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -130,15 +130,6 @@ public function create(
130130
$backendOptions,
131131
$mountOptions
132132
) {
133-
$canCreateNewLocalStorage = $this->config->getSystemValue('files_external_allow_create_new_local', true);
134-
if (!$canCreateNewLocalStorage && $backend === 'local') {
135-
return new DataResponse(
136-
[
137-
'message' => $this->l10n->t('Forbidden to manage local mounts')
138-
],
139-
Http::STATUS_FORBIDDEN
140-
);
141-
}
142133
$newStorage = $this->createStorage(
143134
$mountPoint,
144135
$backend,

0 commit comments

Comments
 (0)