Send 500 errors as JSON in the API
This commit is contained in:
parent
fbb5a359fe
commit
79d0b69345
1 changed files with 1 additions and 1 deletions
|
@ -19,7 +19,7 @@ module API
|
|||
message << " " << trace.join("\n ")
|
||||
|
||||
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
|
||||
|
||||
format :json
|
||||
|
|
Loading…
Reference in a new issue