Merge pull request #38684 from nextcloud/backport/37802/stable26

[stable26] Sharing: Do not show copy action when user doesn't have permissions
This commit is contained in:
Arthur Schiwon 2023-06-14 23:22:05 +02:00 committed by GitHub
commit 99ebcb6dc1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 4 additions and 4 deletions

View file

@ -94,7 +94,7 @@ import { getCapabilities } from '@nextcloud/capabilities'
}
if (_.isFunction(fileData.canDownload) && !fileData.canDownload()) {
delete fileActions.actions.all.Download
if (fileData.permissions & OC.PERMISSION_UPDATE === 0) {
if ((fileData.permissions & OC.PERMISSION_UPDATE) === 0) {
// neither move nor copy is allowed, remove the action completely
delete fileActions.actions.all.MoveCopy
}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long