mirror of
https://github.com/nextcloud/server.git
synced 2026-05-22 10:06:37 -04:00
fix: remove duplicate 'allow creating local storage' check
Signed-off-by: Robin Appelman <robin@icewind.nl>
This commit is contained in:
parent
887dfeb886
commit
728ee257b3
2 changed files with 0 additions and 19 deletions
|
|
@ -77,16 +77,6 @@ class GlobalStoragesController extends StoragesController {
|
|||
?array $applicableGroups,
|
||||
?int $priority,
|
||||
): DataResponse {
|
||||
$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,
|
||||
|
|
|
|||
|
|
@ -102,15 +102,6 @@ class UserStoragesController extends StoragesController {
|
|||
array $backendOptions,
|
||||
?array $mountOptions,
|
||||
): DataResponse {
|
||||
$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