mirror of
https://github.com/ninenines/cowboy.git
synced 2025-07-16 05:00:24 +00:00
Add shortcuts to reply functions
New functions are reply/2, reply/3, chunked_reply/2 in cowboy_http_req.
This commit is contained in:
parent
2a324aca3a
commit
81cc99d10b
5 changed files with 21 additions and 5 deletions
|
@ -6,7 +6,7 @@
|
|||
|
||||
init({_Transport, http}, Req, _Opts) ->
|
||||
Req2 = cowboy_http_req:reply(<<"666 Init Shutdown Testing">>,
|
||||
[{'Connection', <<"close">>}], [], Req),
|
||||
[{'Connection', <<"close">>}], Req),
|
||||
{shutdown, Req2, undefined}.
|
||||
|
||||
handle(Req, State) ->
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue