summaryrefslogtreecommitdiffstats
path: root/apps/files_trashbin/src
diff options
context:
space:
mode:
authorJohn Molakvoæ <skjnldsv@protonmail.com>2023-04-11 11:24:09 +0200
committerJohn Molakvoæ <skjnldsv@protonmail.com>2023-07-05 16:20:32 +0200
commit0984970cd8759ae2dcd7dfdfe41d5816bf3c2948 (patch)
treec215c2dfd3235d9d022f01eb0dd7dbdac969547a /apps/files_trashbin/src
parent79d24bfb8eebd82dd75b15c5503a4bb33563ee69 (diff)
downloadnextcloud-server-0984970cd8759ae2dcd7dfdfe41d5816bf3c2948.tar.gz
nextcloud-server-0984970cd8759ae2dcd7dfdfe41d5816bf3c2948.zip
feat(files): favorites
Signed-off-by: John Molakvoæ <skjnldsv@protonmail.com>
Diffstat (limited to 'apps/files_trashbin/src')
-rw-r--r--apps/files_trashbin/src/services/trashbin.ts16
1 files changed, 5 insertions, 11 deletions
diff --git a/apps/files_trashbin/src/services/trashbin.ts b/apps/files_trashbin/src/services/trashbin.ts
index 9982750ba5c..ab48863317a 100644
--- a/apps/files_trashbin/src/services/trashbin.ts
+++ b/apps/files_trashbin/src/services/trashbin.ts
@@ -25,27 +25,19 @@ import { File, Folder, parseWebdavPermissions } from '@nextcloud/files'
import { generateRemoteUrl, generateUrl } from '@nextcloud/router'
import type { FileStat, ResponseDataDetailed } from 'webdav'
+import { getDavNameSpaces, getDavProperties } from '../../../files/src/services/DavProperties'
import type { ContentsWithRoot } from '../../../files/src/services/Navigation.ts'
import client, { rootPath } from './client'
const data = `<?xml version="1.0"?>
-<d:propfind xmlns:d="DAV:"
- xmlns:oc="http://owncloud.org/ns"
- xmlns:nc="http://nextcloud.org/ns">
+<d:propfind ${getDavNameSpaces()}>
<d:prop>
<nc:trashbin-filename />
<nc:trashbin-deletion-time />
<nc:trashbin-original-location />
<nc:trashbin-title />
- <d:getlastmodified />
- <d:getetag />
- <d:getcontenttype />
- <d:resourcetype />
- <oc:fileid />
- <oc:permissions />
- <oc:size />
- <d:getcontentlength />
+ ${getDavProperties()}
</d:prop>
</d:propfind>`
@@ -73,6 +65,8 @@ const resultToNode = function(node: FileStat): File | Folder {
},
}
+ delete nodeData.attributes.props
+
return node.type === 'file'
? new File(nodeData)
: new Folder(nodeData)