Просмотр исходного кода

Use cow_http_hd:parse_content_length/1 where applicable

Loïc Hoguin 11 лет назад
Родитель
Сommit
dff1b5715c
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      src/cowboy_req.erl

+ 1 - 1
src/cowboy_req.erl

@@ -427,7 +427,7 @@ parse_header(Name = <<"authorization">>, Req, Default) ->
 			cowboy_http:token_ci(Value, fun cowboy_http:authorization/2)
 		end);
 parse_header(Name = <<"content-length">>, Req, Default) ->
-	parse_header(Name, Req, Default, fun cowboy_http:digits/1);
+	parse_header(Name, Req, Default, fun cow_http_hd:parse_content_length/1);
 parse_header(Name = <<"content-type">>, Req, Default) ->
 	parse_header(Name, Req, Default, fun cowboy_http:content_type/1);
 parse_header(Name = <<"cookie">>, Req, Default) ->