mirror of
https://github.com/ninenines/cowboy.git
synced 2025-07-14 12:20:24 +00:00
Get rid of a binary construct in cowboy_http_req
Thanks to @klaar for pointing it out in ticket #59.
This commit is contained in:
parent
ce26d7090b
commit
b79e9fbeb4
1 changed files with 1 additions and 1 deletions
|
@ -346,7 +346,7 @@ response_head(Code, Headers, DefaultHeaders) ->
|
||||||
Headers2 = [{header_to_binary(Key), Value} || {Key, Value} <- Headers],
|
Headers2 = [{header_to_binary(Key), Value} || {Key, Value} <- Headers],
|
||||||
Headers3 = lists:keysort(1, Headers2),
|
Headers3 = lists:keysort(1, Headers2),
|
||||||
Headers4 = lists:ukeymerge(1, Headers3, DefaultHeaders),
|
Headers4 = lists:ukeymerge(1, Headers3, DefaultHeaders),
|
||||||
Headers5 = [<< Key/binary, ": ", Value/binary, "\r\n" >>
|
Headers5 = [[Key, <<": ">>, Value, <<"\r\n">>]
|
||||||
|| {Key, Value} <- Headers4],
|
|| {Key, Value} <- Headers4],
|
||||||
[StatusLine, Headers5, <<"\r\n">>].
|
[StatusLine, Headers5, <<"\r\n">>].
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue