Commit 79d0b693 authored by jubianchi's avatar jubianchi

Send 500 errors as JSON in the API

parent fbb5a359
...@@ -19,7 +19,7 @@ module API ...@@ -19,7 +19,7 @@ module API
message << " " << trace.join("\n ") message << " " << trace.join("\n ")
API.logger.add Logger::FATAL, message API.logger.add Logger::FATAL, message
rack_response({ 'message' => '500 Internal Server Error' }, 500) rack_response({ 'message' => '500 Internal Server Error' }.to_json, 500)
end end
format :json format :json
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment