Skip to content

Commit

Permalink
Merge pull request #282 from nextcloud/skjnldsv-patch-1
Browse files Browse the repository at this point in the history
  • Loading branch information
juliusknorr authored Sep 11, 2024
2 parents 5d178fc + 2fe7b88 commit 50299d7
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,10 @@ const fileAction = new FileAction({
displayName() {
return t('files_zip', 'Compress to Zip')
},
enabled(nodes: Node[]) {
enabled(nodes: Node[], view: View) {
if (view.id === 'trashbin') {
return false
}
return nodes.filter((node) => (node.permissions & Permission.READ) !== 0).length > 0
},
async execBatch(nodes: Node[], view: View, dir: string) {
Expand Down

0 comments on commit 50299d7

Please sign in to comment.