diff options
author | Bernhard Posselt <nukeawhale@gmail.com> | 2013-08-31 02:58:56 +0200 |
---|---|---|
committer | Bernhard Posselt <nukeawhale@gmail.com> | 2013-08-31 02:58:56 +0200 |
commit | 7036a1407c3dce54a6ac5e283ba55720f85ba7de (patch) | |
tree | 7c5fae7ab816a2b0c56b92ca74ebc7cc591d5a3d /external/feedapi.php | |
parent | 6f23208ff68d4a8bf2fc20b1fcad6b5e636fb584 (diff) |
Throw proper error codes when creating invalid folders through the API, fix #297
Diffstat (limited to 'external/feedapi.php')
-rw-r--r-- | external/feedapi.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/external/feedapi.php b/external/feedapi.php index a9fdb4c70..be228d490 100644 --- a/external/feedapi.php +++ b/external/feedapi.php @@ -35,7 +35,7 @@ use \OCA\News\BusinessLayer\FeedBusinessLayer; use \OCA\News\BusinessLayer\FolderBusinessLayer; use \OCA\News\BusinessLayer\ItemBusinessLayer; use \OCA\News\BusinessLayer\BusinessLayerException; -use \OCA\News\BusinessLayer\BusinessLayerExistsException; +use \OCA\News\BusinessLayer\BusinessLayerConflictException; class FeedAPI extends Controller { @@ -112,7 +112,7 @@ class FeedAPI extends Controller { return new JSONResponse($result); - } catch(BusinessLayerExistsException $ex) { + } catch(BusinessLayerConflictException $ex) { return new JSONResponse(array('message' => $ex->getMessage()), Http::STATUS_CONFLICT); } catch(BusinessLayerException $ex) { |