Merge pull request #49291 from nextcloud/encoding-wrapper-metadata

fix: don't set 'name' on null metadata
pull/49637/head
Côme Chilliet 2024-12-03 21:47:46 +07:00 committed by GitHub
commit 0729e264f5
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 3 additions and 1 deletions

@ -280,7 +280,9 @@ class Encoding extends Wrapper {
public function getMetaData(string $path): ?array {
$entry = $this->storage->getMetaData($this->findPathToUse($path));
$entry['name'] = trim(Filesystem::normalizePath($entry['name']), '/');
if ($entry !== null) {
$entry['name'] = trim(Filesystem::normalizePath($entry['name']), '/');
}
return $entry;
}