mirror of
https://github.com/edgurgel/httparrot
synced 2025-04-10 04:02:28 -04:00
Fix req being used in an unsafe way.
This fixes a warning that occurs in Elixir 1.3
This commit is contained in:
parent
9152dff745
commit
d4e826cd5b
1 changed files with 3 additions and 1 deletions
|
@ -62,7 +62,9 @@ defmodule HTTParrot do
|
|||
body = JSX.prettify!(body)
|
||||
headers = List.keystore(headers, "content-length", 0, {"content-length", Integer.to_char_list(String.length(body))})
|
||||
{:ok, req} = :cowboy_req.reply(status, headers, body, req)
|
||||
req
|
||||
else
|
||||
req
|
||||
end
|
||||
req
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Reference in a new issue