diff --git a/build/psalm-baseline.xml b/build/psalm-baseline.xml
index 9243b71bc5dab..c837e74952171 100644
--- a/build/psalm-baseline.xml
+++ b/build/psalm-baseline.xml
@@ -3509,11 +3509,6 @@
getStorageInfo($storageId)]]>
-
-
-
-
-
diff --git a/lib/private/Files/Cache/Wrapper/CacheWrapper.php b/lib/private/Files/Cache/Wrapper/CacheWrapper.php
index 06e94ae146317..ff1953b230486 100644
--- a/lib/private/Files/Cache/Wrapper/CacheWrapper.php
+++ b/lib/private/Files/Cache/Wrapper/CacheWrapper.php
@@ -97,14 +97,14 @@ public function getFolderContents(string $folder, ?string $mimeTypeFilter = null
}
/**
- * get the metadata of all files stored in $folder
+ * Get the metadata of all files stored in given folder
*
* @param int $fileId the file id of the folder
- * @return array
+ * @return ICacheEntry[]
*/
public function getFolderContentsById(int $fileId, ?string $mimeTypeFilter = null) {
$results = $this->getCache()->getFolderContentsById($fileId, $mimeTypeFilter);
- return array_map($this->formatCacheEntry(...), $results);
+ return array_filter(array_map($this->formatCacheEntry(...), $results));
}
/**