aboutsummaryrefslogtreecommitdiffstats
path: root/src/cowboy_req.erl
diff options
context:
space:
mode:
Diffstat (limited to 'src/cowboy_req.erl')
-rw-r--r--src/cowboy_req.erl2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/cowboy_req.erl b/src/cowboy_req.erl
index 14eb88d..5b8cb7e 100644
--- a/src/cowboy_req.erl
+++ b/src/cowboy_req.erl
@@ -1108,7 +1108,7 @@ response(Status, Headers, RespHeaders, DefaultHeaders, Body, Req=#http_req{
FullHeaders = response_merge_headers(Headers, RespHeaders, DefaultHeaders),
Req2 = case OnResponse of
undefined -> Req;
- OnResponse -> OnResponse(Status, FullHeaders,
+ OnResponse -> OnResponse(Status, FullHeaders, Body,
%% Don't call 'onresponse' from the hook itself.
Req#http_req{resp_headers=[], resp_body= <<>>,
onresponse=undefined})