Merge pull request #46694 from nextcloud/fix/file-info-name

fix: FileInfo from `View` should have the correct name of a mountpoint
This commit is contained in:
Stephan Orbaugh 2024-07-24 15:22:11 +02:00 committed by GitHub
commit 52fe7b1a12
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1357,6 +1357,10 @@ class View {
if ($mount instanceof MoveableMount && $internalPath === '') {
$data['permissions'] |= \OCP\Constants::PERMISSION_DELETE;
}
if ($internalPath === '' && $data['name']) {
$data['name'] = basename($path);
}
$ownerId = $storage->getOwner($internalPath);
$owner = null;
if ($ownerId !== null && $ownerId !== false) {