YUKI Hiroshi
null+****@clear*****
Thu Oct 18 17:48:11 JST 2012
YUKI Hiroshi 2012-10-18 17:48:11 +0900 (Thu, 18 Oct 2012) New Revision: 447a6a1d45a8dff277576cf5ca830f1611cac892 https://github.com/groonga/gcs/commit/447a6a1d45a8dff277576cf5ca830f1611cac892 Log: Handle any error and return XML response Modified files: lib/api/2011-02-01/configuration.js Modified: lib/api/2011-02-01/configuration.js (+7 -1) =================================================================== --- lib/api/2011-02-01/configuration.js 2012-10-18 17:41:48 +0900 (d688b6b) +++ lib/api/2011-02-01/configuration.js 2012-10-18 17:48:11 +0900 (fcadcf8) @@ -534,6 +534,12 @@ exports.createHandler = function(context, config) { } var handler = handlers[action]; - handler(context, request, response, config); + try { + handler(context, request, response, config); + } catch (error) { + var body = createCommonErrorResponse('InternalFailure', error); + response.contentType('application/xml'); + response.send(body, 400); + } }; }; -------------- next part -------------- HTML����������������������������...Download