Skip to content

Commit

Permalink
Merge pull request #41054 from nextcloud/systemtag-children
Browse files Browse the repository at this point in the history
get children from dav node when preloading system tags
  • Loading branch information
icewind1991 authored Nov 8, 2023
2 parents 77c9550 + 4a049c2 commit 1acc7c0
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions apps/dav/lib/SystemTag/SystemTagPlugin.php
Original file line number Diff line number Diff line change
Expand Up @@ -303,9 +303,11 @@ private function propfindForFile(PropFind $propFind, Node $node): void {
$fileIds = [$node->getId()];

// note: pre-fetching only supported for depth <= 1
$folderContent = $node->getNode()->getDirectoryListing();
$folderContent = $node->getChildren();
foreach ($folderContent as $info) {
$fileIds[] = $info->getId();
if ($info instanceof Node) {
$fileIds[] = $info->getId();
}
}

$tags = $this->tagMapper->getTagIdsForObjects($fileIds, 'files');
Expand Down

0 comments on commit 1acc7c0

Please sign in to comment.