Catch NotFoundException when querying quota

Fixes parent folder that becomes inaccessible when it contains a
non-existing / broken entry because the quota check made the PROPFIND
on parent fail altogether.

Signed-off-by: Vincent Petry <vincent@nextcloud.com>
This commit is contained in:
Vincent Petry 2021-01-25 12:02:14 +01:00
parent b98860eeb3
commit 65da8bd76e
No known key found for this signature in database
GPG Key ID: E055D6A4D513575C
1 changed files with 2 additions and 0 deletions

View File

@ -339,6 +339,8 @@ class Directory extends \OCA\DAV\Connector\Sabre\Node implements \Sabre\DAV\ICol
$free
];
return $this->quotaInfo;
} catch (\OCP\Files\NotFoundException $e) {
return [0, 0];
} catch (\OCP\Files\StorageNotAvailableException $e) {
return [0, 0];
}