add debug
This commit is contained in:
parent
d353cf8bef
commit
9f5ad1c646
@ -21,8 +21,8 @@ init(Req0, Opts = [Mod|_]) ->
|
|||||||
|
|
||||||
try Mod:handle_request(Method, Path, GetParams, PostParams) of
|
try Mod:handle_request(Method, Path, GetParams, PostParams) of
|
||||||
{ok, StatusCode, Resp} ->
|
{ok, StatusCode, Resp} ->
|
||||||
%logger:debug("[http_protocol] request path: ~p, get_params: ~p, post_params: ~p, response: ~ts",
|
logger:debug("[http_protocol] request path: ~p, get_params: ~p, post_params: ~p, response: ~ts",
|
||||||
% [Path, GetParams, PostParams, Resp]),
|
[Path, GetParams, PostParams, Resp]),
|
||||||
AcceptEncoding = cowboy_req:header(<<"accept-encoding">>, Req1, <<>>),
|
AcceptEncoding = cowboy_req:header(<<"accept-encoding">>, Req1, <<>>),
|
||||||
Req2 = case iolist_size(Resp) >= 1024 andalso supported_gzip(AcceptEncoding) of
|
Req2 = case iolist_size(Resp) >= 1024 andalso supported_gzip(AcceptEncoding) of
|
||||||
true ->
|
true ->
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user