aboutsummaryrefslogtreecommitdiffstats
path: root/app/controllers/api_controller.rb
diff options
context:
space:
mode:
authorSeb Bacon <seb.bacon@gmail.com>2012-07-09 12:43:55 +0100
committerLouise Crow <louise.crow@gmail.com>2012-08-16 15:33:53 +0100
commit32f44e53c879481198bdc02044d4fd3c892ce801 (patch)
treec9db7f8957fc1148e5d54e647b57a94e8ea93d57 /app/controllers/api_controller.rb
parent4505c80c14dd0b34222aec3d398e7b16d076feb8 (diff)
Calls to API that are expected to return JSON are always expected to return something, even when there are no errors.
Diffstat (limited to 'app/controllers/api_controller.rb')
-rw-r--r--app/controllers/api_controller.rb5
1 files changed, 3 insertions, 2 deletions
diff --git a/app/controllers/api_controller.rb b/app/controllers/api_controller.rb
index 4db07b4c9..718c31e6f 100644
--- a/app/controllers/api_controller.rb
+++ b/app/controllers/api_controller.rb
@@ -151,8 +151,9 @@ class ApiController < ApplicationController
mail = RequestMailer.create_external_response(request, body, sent_at, attachment_hashes)
request.receive(mail, mail.encoded, true)
end
-
- head :no_content
+ render :json => {
+ 'url' => make_url("request", request.url_title),
+ }
end
def body_request_events