mirror of
https://github.com/nextcloud/server.git
synced 2026-06-15 19:49:38 -04:00
fix: remove duplicate 'allow creating local storage' check
Signed-off-by: Robin Appelman <robin@icewind.nl>
This commit is contained in:
parent
2c21d7517b
commit
7fac3ae9c9
2 changed files with 0 additions and 19 deletions
|
|
@ -81,16 +81,6 @@ class GlobalStoragesController extends StoragesController {
|
|||
$applicableGroups,
|
||||
$priority,
|
||||
) {
|
||||
$canCreateNewLocalStorage = $this->config->getSystemValue('files_external_allow_create_new_local', true);
|
||||
if (!$canCreateNewLocalStorage && $backend === 'local') {
|
||||
return new DataResponse(
|
||||
[
|
||||
'message' => $this->l10n->t('Forbidden to manage local mounts')
|
||||
],
|
||||
Http::STATUS_FORBIDDEN
|
||||
);
|
||||
}
|
||||
|
||||
$newStorage = $this->createStorage(
|
||||
$mountPoint,
|
||||
$backend,
|
||||
|
|
|
|||
|
|
@ -108,15 +108,6 @@ class UserStoragesController extends StoragesController {
|
|||
$backendOptions,
|
||||
$mountOptions,
|
||||
) {
|
||||
$canCreateNewLocalStorage = $this->config->getSystemValue('files_external_allow_create_new_local', true);
|
||||
if (!$canCreateNewLocalStorage && $backend === 'local') {
|
||||
return new DataResponse(
|
||||
[
|
||||
'message' => $this->l10n->t('Forbidden to manage local mounts')
|
||||
],
|
||||
Http::STATUS_FORBIDDEN
|
||||
);
|
||||
}
|
||||
$newStorage = $this->createStorage(
|
||||
$mountPoint,
|
||||
$backend,
|
||||
|
|
|
|||
Loading…
Reference in a new issue