]> source.dussan.org Git - nextcloud-server.git/commitdiff
fix: fix getting the folder node from the dav response
authorRobin Appelman <robin@icewind.nl>
Fri, 9 Aug 2024 13:17:57 +0000 (15:17 +0200)
committerbackportbot[bot] <backportbot[bot]@users.noreply.github.com>
Sat, 10 Aug 2024 12:49:31 +0000 (12:49 +0000)
Signed-off-by: Robin Appelman <robin@icewind.nl>
apps/files_trashbin/src/services/trashbin.ts

index e7744463011e1bba3d25d94e76feaab9bba6fbe6..deab215a25c671d7edfef8cfc78556b875869933 100644 (file)
@@ -50,7 +50,7 @@ export const getContents = async (path = '/'): Promise<ContentsWithRoot> => {
        }) as ResponseDataDetailed<FileStat[]>
 
        const contents = contentsResponse.data.map(resultToNode)
-       const [folder] = contents.splice(contents.findIndex((node) => node.dirname === path), 1)
+       const [folder] = contents.splice(contents.findIndex((node) => node.path === path), 1)
 
        return {
                folder: folder as Folder,