diff options
author | Robin Appelman <robin@icewind.nl> | 2018-11-16 20:21:21 +0100 |
---|---|---|
committer | Morris Jobke <hey@morrisjobke.de> | 2018-11-19 11:37:12 +0100 |
commit | 5261edb61ab0a234f241d8d29b5140f1433f26d6 (patch) | |
tree | 9730ae300f72a33d4c557c8a593f0100f2c56388 /apps/dav | |
parent | 24a04fae3dbded2e190ca3089fc4b67763fab9f3 (diff) | |
download | nextcloud-server-5261edb61ab0a234f241d8d29b5140f1433f26d6.tar.gz nextcloud-server-5261edb61ab0a234f241d8d29b5140f1433f26d6.zip |
forward object not found error in swift as dav 404
Signed-off-by: Robin Appelman <robin@icewind.nl>
Diffstat (limited to 'apps/dav')
-rw-r--r-- | apps/dav/lib/Connector/Sabre/File.php | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/apps/dav/lib/Connector/Sabre/File.php b/apps/dav/lib/Connector/Sabre/File.php index 2b3956e2baf..a3d1861db28 100644 --- a/apps/dav/lib/Connector/Sabre/File.php +++ b/apps/dav/lib/Connector/Sabre/File.php @@ -50,6 +50,7 @@ use OCP\Files\ForbiddenException; use OCP\Files\InvalidContentException; use OCP\Files\InvalidPathException; use OCP\Files\LockNotAcquiredException; +use OCP\Files\NotFoundException; use OCP\Files\NotPermittedException; use OCP\Files\StorageNotAvailableException; use OCP\Lock\ILockingProvider; @@ -353,6 +354,8 @@ class File extends Node implements IFile { throw new DAVForbiddenException($ex->getMessage(), $ex->getRetry()); } catch (LockedException $e) { throw new FileLocked($e->getMessage(), $e->getCode(), $e); + } catch (NotFoundException $e) { + throw new NotFound('File not found: ' . $e->getMessage(), $e->getCode(), $e); } } |