mirror of
https://github.com/nextcloud/server.git
synced 2026-05-19 08:25:56 -04:00
Merge pull request #32138 from nextcloud/stable24-directory-listing-optimize-add-submount
[stable24] optimize adding submount info to directory content
This commit is contained in:
commit
ff64a731b0
1 changed files with 2 additions and 4 deletions
|
|
@ -1517,10 +1517,8 @@ class View {
|
|||
if ($pos = strpos($relativePath, '/')) {
|
||||
//mountpoint inside subfolder add size to the correct folder
|
||||
$entryName = substr($relativePath, 0, $pos);
|
||||
foreach ($files as &$entry) {
|
||||
if ($entry->getName() === $entryName) {
|
||||
$entry->addSubEntry($rootEntry, $mountPoint);
|
||||
}
|
||||
if (isset($files[$entryName])) {
|
||||
$files[$entryName]->addSubEntry($rootEntry, $mountPoint);
|
||||
}
|
||||
} else { //mountpoint in this folder, add an entry for it
|
||||
$rootEntry['name'] = $relativePath;
|
||||
|
|
|
|||
Loading…
Reference in a new issue