diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/cowboy_http.erl | 11 | ||||
-rw-r--r-- | src/cowboy_req.erl | 3 |
2 files changed, 6 insertions, 8 deletions
diff --git a/src/cowboy_http.erl b/src/cowboy_http.erl index 57dac0b..b958020 100644 --- a/src/cowboy_http.erl +++ b/src/cowboy_http.erl @@ -157,8 +157,7 @@ cookie_name(Data = << C, _Rest/binary >>, Fun, Acc) C =:= $\r; C =:= $\n; C =:= $\013; C =:= $\014 -> Fun(Data, Acc); cookie_name(<< C, Rest/binary >>, Fun, Acc) -> - C2 = cowboy_bstr:char_to_lower(C), - cookie_name(Rest, Fun, << Acc/binary, C2 >>). + cookie_name(Rest, Fun, << Acc/binary, C >>). -spec cookie_value(binary(), fun()) -> any(). cookie_value(Data, Fun) -> @@ -1110,14 +1109,14 @@ cookie_list_test_() -> {<<"name2">>, <<"value2">>} ]}, {<<"$Version=1; Customer=WILE_E_COYOTE; $Path=/acme">>, [ - {<<"customer">>, <<"WILE_E_COYOTE">>} + {<<"Customer">>, <<"WILE_E_COYOTE">>} ]}, {<<"$Version=1; Customer=WILE_E_COYOTE; $Path=/acme; " "Part_Number=Rocket_Launcher_0001; $Path=/acme; " "Shipping=FedEx; $Path=/acme">>, [ - {<<"customer">>, <<"WILE_E_COYOTE">>}, - {<<"part_number">>, <<"Rocket_Launcher_0001">>}, - {<<"shipping">>, <<"FedEx">>} + {<<"Customer">>, <<"WILE_E_COYOTE">>}, + {<<"Part_Number">>, <<"Rocket_Launcher_0001">>}, + {<<"Shipping">>, <<"FedEx">>} ]}, %% Potential edge cases (initially from Mochiweb). {<<"foo=\\x">>, [{<<"foo">>, <<"\\x">>}]}, diff --git a/src/cowboy_req.erl b/src/cowboy_req.erl index 4ec42f9..11b0e26 100644 --- a/src/cowboy_req.erl +++ b/src/cowboy_req.erl @@ -29,8 +29,7 @@ %% </dl> %% %% Exceptions include <em>chunk/2</em> which always returns <em>'ok'</em>, -%% <em>to_list/1</em> which returns a list of key/values, -%% and <em>transport/1</em> which returns <em>{ok, Transport, Socket}</em>. +%% and <em>to_list/1</em> which returns a list of key/values. %% %% Also note that all body reading functions perform actions, as Cowboy %% doesn't read the request body until they are called. |