Skip to content

Commit 58f5523

Browse files
committed
fix: use mint passive mode
1 parent e7c4371 commit 58f5523

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

lib/tesla/adapter/mint.ex

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -155,6 +155,8 @@ if Code.ensure_loaded?(Mint.HTTP) do
155155
_ -> opts
156156
end
157157

158+
opts = Map.put_new(opts, :mode, :passive)
159+
158160
with {:ok, conn} <-
159161
HTTP.connect(String.to_atom(uri.scheme), uri.host, uri.port, Enum.into(opts, [])) do
160162
# If there were redirects, and passed `closed_conn: false`, we need to close opened connections to these intermediate hosts.

0 commit comments

Comments
 (0)