Skip to content

Commit

Permalink
fix(files): Show non writable folders during move or copy
Browse files Browse the repository at this point in the history
Signed-off-by: Louis Chemineau <louis@chmn.me>
  • Loading branch information
artonge committed Jun 6, 2024
1 parent ad73418 commit 580352a
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions apps/files/src/actions/moveOrCopyAction.ts
Original file line number Diff line number Diff line change
Expand Up @@ -182,10 +182,8 @@ const openFilePickerForAction = async (action: MoveCopyAction, dir = '/', nodes:
const filePicker = getFilePickerBuilder(t('files', 'Choose destination'))
.allowDirectories(true)
.setFilter((n: Node) => {
// We only want to show folders that we can create nodes in
return (n.permissions & Permission.CREATE) !== 0
// We don't want to show the current nodes in the file picker
&& !fileIDs.includes(n.fileid)
// We don't want to show the current nodes in the file picker
return !fileIDs.includes(n.fileid)
})
.setMimeTypeFilter([])
.setMultiSelect(false)
Expand Down

0 comments on commit 580352a

Please sign in to comment.