Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/processone/ejabberd.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBadlop <badlop@process-one.net>2016-09-28 12:03:46 +0300
committerBadlop <badlop@process-one.net>2016-09-28 12:03:46 +0300
commit6f538545b49d371db9b9ad2a346563692479e587 (patch)
treef4147a7473408d98a4af70abf3f2675fba946190 /src/mod_http_api.erl
parentd4b4f35a0ecff8fdad416a7f3bab85a2b7a7e375 (diff)
Fix 404 response formatting (thanks to Kaggggggga)(#1306)
Diffstat (limited to 'src/mod_http_api.erl')
-rw-r--r--src/mod_http_api.erl2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mod_http_api.erl b/src/mod_http_api.erl
index dbca82375..7a95f8c6f 100644
--- a/src/mod_http_api.erl
+++ b/src/mod_http_api.erl
@@ -226,7 +226,7 @@ process([Call], #request{method = 'POST', data = Data, ip = {IP, _} = IPPort} =
catch
%% TODO We need to refactor to remove redundant error return formatting
throw:{error, unknown_command} ->
- {404, 40, <<"Command not found.">>};
+ json_format({404, 44, <<"Command not found.">>});
_:{error,{_,invalid_json}} = _Err ->
?DEBUG("Bad Request: ~p", [_Err]),
badrequest_response(<<"Invalid JSON input">>);