mirror of
https://github.com/ninenines/cowboy.git
synced 2025-07-14 12:20:24 +00:00
Only address the specific quoted_string issue
This commit is contained in:
parent
07ef3c32d7
commit
aa2d41951a
1 changed files with 2 additions and 6 deletions
|
@ -523,7 +523,7 @@ resource_exists(Req, State) ->
|
||||||
|
|
||||||
if_match_exists(Req, State) ->
|
if_match_exists(Req, State) ->
|
||||||
State2 = State#state{exists=true},
|
State2 = State#state{exists=true},
|
||||||
try cowboy_req:parse_header(<<"if-match">>, Req) of
|
case cowboy_req:parse_header(<<"if-match">>, Req) of
|
||||||
{ok, undefined, Req2} ->
|
{ok, undefined, Req2} ->
|
||||||
if_unmodified_since_exists(Req2, State2);
|
if_unmodified_since_exists(Req2, State2);
|
||||||
{ok, '*', Req2} ->
|
{ok, '*', Req2} ->
|
||||||
|
@ -532,8 +532,6 @@ if_match_exists(Req, State) ->
|
||||||
if_match(Req2, State2, ETagsList);
|
if_match(Req2, State2, ETagsList);
|
||||||
{error, badarg} ->
|
{error, badarg} ->
|
||||||
respond(Req, State2, 400)
|
respond(Req, State2, 400)
|
||||||
catch Class:Reason ->
|
|
||||||
error_terminate(Req, State2, Class, Reason, if_match)
|
|
||||||
end.
|
end.
|
||||||
|
|
||||||
if_match(Req, State, EtagsList) ->
|
if_match(Req, State, EtagsList) ->
|
||||||
|
@ -577,7 +575,7 @@ if_unmodified_since(Req, State, IfUnmodifiedSince) ->
|
||||||
end.
|
end.
|
||||||
|
|
||||||
if_none_match_exists(Req, State) ->
|
if_none_match_exists(Req, State) ->
|
||||||
try cowboy_req:parse_header(<<"if-none-match">>, Req) of
|
case cowboy_req:parse_header(<<"if-none-match">>, Req) of
|
||||||
{ok, undefined, Req2} ->
|
{ok, undefined, Req2} ->
|
||||||
if_modified_since_exists(Req2, State);
|
if_modified_since_exists(Req2, State);
|
||||||
{ok, '*', Req2} ->
|
{ok, '*', Req2} ->
|
||||||
|
@ -586,8 +584,6 @@ if_none_match_exists(Req, State) ->
|
||||||
if_none_match(Req2, State, EtagsList);
|
if_none_match(Req2, State, EtagsList);
|
||||||
{error, badarg} ->
|
{error, badarg} ->
|
||||||
respond(Req, State, 400)
|
respond(Req, State, 400)
|
||||||
catch Class:Reason ->
|
|
||||||
error_terminate(Req, State, Class, Reason, if_none_match)
|
|
||||||
end.
|
end.
|
||||||
|
|
||||||
if_none_match(Req, State, EtagsList) ->
|
if_none_match(Req, State, EtagsList) ->
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue