diff options
author | Morris Jobke <hey@morrisjobke.de> | 2017-05-01 18:41:37 -0300 |
---|---|---|
committer | Robin Appelman <robin@icewind.nl> | 2017-05-02 13:43:48 +0200 |
commit | 23cc309606443003c3478d96452998b109ea9c09 (patch) | |
tree | aa2459d4c6abda0415dcb623e9716fdf9ef8e279 /core/Controller/PreviewController.php | |
parent | 6aac094091076d503d6376ca74d2bedadff63de7 (diff) | |
download | nextcloud-server-23cc309606443003c3478d96452998b109ea9c09.tar.gz nextcloud-server-23cc309606443003c3478d96452998b109ea9c09.zip |
Handle more error cases
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
Diffstat (limited to 'core/Controller/PreviewController.php')
-rw-r--r-- | core/Controller/PreviewController.php | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/core/Controller/PreviewController.php b/core/Controller/PreviewController.php index 4b9ba8b60d4..4e2b2f0287a 100644 --- a/core/Controller/PreviewController.php +++ b/core/Controller/PreviewController.php @@ -126,6 +126,8 @@ class PreviewController extends Controller { return $response; } catch (NotFoundException $e) { return new DataResponse([], Http::STATUS_NOT_FOUND); + } catch (\InvalidArgumentException $e) { + return new DataResponse([], Http::STATUS_BAD_REQUEST); } } |