diff --git a/lib/api.rb b/lib/api.rb index de03d42..ba08ae1 100644 --- a/lib/api.rb +++ b/lib/api.rb @@ -30,7 +30,7 @@ helpers do end def halt_with_meaningful_response(status, message) - halt status, message + halt status, Yajl::Encoder.encode(error: { status: status, message: message }) end end