aboutsummaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
authorRobin Appelman <robin@icewind.nl>2023-09-18 13:53:18 +0200
committerGitHub <noreply@github.com>2023-09-18 13:53:18 +0200
commit2fad5233a2e7db1e0f7577b5cc899096cb8d8707 (patch)
tree9541571596883e5dcfcddb60fde41e2db26df4ac /apps
parent5a22eb7016205e7c1ca21874080f74c002ee9f20 (diff)
parente14858007d6efba4c543d32cfdfa90070afed422 (diff)
downloadnextcloud-server-2fad5233a2e7db1e0f7577b5cc899096cb8d8707.tar.gz
nextcloud-server-2fad5233a2e7db1e0f7577b5cc899096cb8d8707.zip
Merge pull request #40473 from nextcloud/backport/39860/stable27
[stable27] don't preload metadata for the sub-childen
Diffstat (limited to 'apps')
-rw-r--r--apps/dav/lib/Connector/Sabre/FilesPlugin.php16
1 files changed, 10 insertions, 6 deletions
diff --git a/apps/dav/lib/Connector/Sabre/FilesPlugin.php b/apps/dav/lib/Connector/Sabre/FilesPlugin.php
index ae3caa29b91..709a4cd68ed 100644
--- a/apps/dav/lib/Connector/Sabre/FilesPlugin.php
+++ b/apps/dav/lib/Connector/Sabre/FilesPlugin.php
@@ -465,13 +465,17 @@ class FilesPlugin extends ServerPlugin {
$requestProperties = $propFind->getRequestedProperties();
- if ($this->config->getSystemValueBool('enable_file_metadata', true)) {
- $requestedMetaData = [];
- foreach ($requestProperties as $requestProperty) {
- if (isset(self::ALL_METADATA_PROPS[$requestProperty])) {
- $requestedMetaData[] = self::ALL_METADATA_PROPS[$requestProperty];
- }
+ $requestedMetaData = [];
+ foreach ($requestProperties as $requestProperty) {
+ if (isset(self::ALL_METADATA_PROPS[$requestProperty])) {
+ $requestedMetaData[] = self::ALL_METADATA_PROPS[$requestProperty];
}
+ }
+ if (
+ $this->config->getSystemValueBool('enable_file_metadata', true) &&
+ $propFind->getDepth() === 1 &&
+ $requestedMetaData
+ ) {
$children = $node->getChildren();
// Preloading of the metadata