mirror of
https://github.com/ninenines/cowboy.git
synced 2025-07-16 13:10:24 +00:00
Merge branch 'multipart' of https://github.com/nox/cowboy
Conflicts: src/cowboy_http_req.erl test/http_SUITE.erl
This commit is contained in:
commit
b650ef8907
7 changed files with 376 additions and 7 deletions
|
@ -380,7 +380,10 @@ ensure_body_processed(Req=#http_req{body_state=waiting}) ->
|
|||
{error, badarg} -> ok; %% No body.
|
||||
{error, _Reason} -> close;
|
||||
_Any -> ok
|
||||
end.
|
||||
end;
|
||||
ensure_body_processed(Req=#http_req{body_state={multipart, _, _}}) ->
|
||||
{ok, Req2} = cowboy_http_req:multipart_skip(Req),
|
||||
ensure_body_processed(Req2).
|
||||
|
||||
-spec ensure_response(#http_req{}) -> ok.
|
||||
%% The handler has already fully replied to the client.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue