From e093fde18cd29e655b408c2ccc219c1fd574539c Mon Sep 17 00:00:00 2001 From: Piotr Sarnacki Date: Mon, 5 Aug 2013 02:18:10 +0200 Subject: [PATCH] Return error with application/json content type by default --- lib/travis/api/app.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/travis/api/app.rb b/lib/travis/api/app.rb index 59e58af8..0c85e17c 100644 --- a/lib/travis/api/app.rb +++ b/lib/travis/api/app.rb @@ -113,7 +113,7 @@ module Travis::Api app.call(env) rescue if Endpoint.production? - [500, {'Content-Type' => 'text/plain'}, ['Travis encountered an error, sorry :(']] + [500, {'Content-Type' => 'application/json'}, ["{'error': 'Travis encountered an error, sorry :('}"]] else raise end