Skip to content

Commit

Permalink
fix(files_sharing): Don't show copy action when !canDownload and no u…
Browse files Browse the repository at this point in the history
…pdate permissions

Signed-off-by: Marcel Klehr <mklehr@gmx.net>
  • Loading branch information
marcelklehr committed May 2, 2023
1 parent 436a088 commit af66537
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion apps/files_sharing/src/share.js
Original file line number Diff line number Diff line change
Expand Up @@ -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
}
Expand Down

0 comments on commit af66537

Please sign in to comment.