mirror of
https://github.com/nextcloud/server.git
synced 2026-06-11 01:30:50 -04:00
fix(files): Disable copy-move-action of single file shares
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
This commit is contained in:
parent
f109c1a044
commit
f0a765ee46
1 changed files with 5 additions and 1 deletions
|
|
@ -265,7 +265,11 @@ export const action = new FileAction({
|
|||
}
|
||||
},
|
||||
iconSvgInline: () => FolderMoveSvg,
|
||||
enabled(nodes: Node[]) {
|
||||
enabled(nodes: Node[], view: View) {
|
||||
// We can not copy or move in single file shares
|
||||
if (view.id === 'public-file-share') {
|
||||
return false
|
||||
}
|
||||
// We only support moving/copying files within the user folder
|
||||
if (!nodes.every(node => node.root?.startsWith('/files/'))) {
|
||||
return false
|
||||
|
|
|
|||
Loading…
Reference in a new issue