diff options
author | skjnldsv <skjnldsv@protonmail.com> | 2024-07-26 09:55:01 +0200 |
---|---|---|
committer | nextcloud-command <nextcloud-command@users.noreply.github.com> | 2024-07-30 09:52:48 +0000 |
commit | 6427ae104c232b65352aabeff00f088df8ee911b (patch) | |
tree | 4b1c8e81ec6fedab55f69e96123546a5e6103509 /apps/files_sharing | |
parent | 197c35598cc6b1b8142a45afa89d213f8338d3f3 (diff) | |
download | nextcloud-server-6427ae104c232b65352aabeff00f088df8ee911b.tar.gz nextcloud-server-6427ae104c232b65352aabeff00f088df8ee911b.zip |
fix(files_sharing): always show file request creation option
Signed-off-by: skjnldsv <skjnldsv@protonmail.com>
Signed-off-by: nextcloud-command <nextcloud-command@users.noreply.github.com>
Diffstat (limited to 'apps/files_sharing')
-rw-r--r-- | apps/files_sharing/src/new/newFileRequest.ts | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/apps/files_sharing/src/new/newFileRequest.ts b/apps/files_sharing/src/new/newFileRequest.ts index 7d859e1268a..c069bf5cdea 100644 --- a/apps/files_sharing/src/new/newFileRequest.ts +++ b/apps/files_sharing/src/new/newFileRequest.ts @@ -4,7 +4,6 @@ */ import type { Entry, Folder, Node } from '@nextcloud/files' -import { Permission } from '@nextcloud/files' import { translate as t } from '@nextcloud/l10n' import FileUploadSvg from '@mdi/svg/svg/file-upload.svg?raw' import Vue, { defineAsyncComponent } from 'vue' @@ -21,12 +20,9 @@ export const entry = { displayName: t('files_sharing', 'Create file request'), iconSvgInline: FileUploadSvg, order: 30, - enabled(context: Folder): boolean { - if ((context.permissions & Permission.SHARE) !== 0) { - // We need to have either link shares creation permissions - return sharingConfig.isPublicShareAllowed - } - return false + enabled(): boolean { + // We will check for the folder permission on the dialog + return sharingConfig.isPublicShareAllowed }, async handler(context: Folder, content: Node[]) { // Create document root |