ignore forbidden files while scanning local storage

Signed-off-by: Robin Appelman <robin@icewind.nl>
pull/32024/head
Robin Appelman 2022-04-20 13:01:16 +07:00
parent 58f5de08df
commit 468d6a9cf1
No known key found for this signature in database
GPG Key ID: 42B69D8A64526EFB
1 changed files with 5 additions and 1 deletions

@ -173,7 +173,11 @@ class Local extends \OC\Files\Storage\Common {
* @inheritdoc
*/
public function getMetaData($path) {
$stat = $this->stat($path);
try {
$stat = $this->stat($path);
} catch (ForbiddenException $e) {
return null;
}
if (!$stat) {
return null;
}