mirror of
https://akkoma.dev/AkkomaGang/akkoma.git
synced 2024-11-18 10:59:17 +00:00
return error if connection failed to open
This commit is contained in:
parent
7d68924e4f
commit
8fc00b7cbf
|
@ -90,7 +90,7 @@ defp do_open(uri, %{proxy: {proxy_host, proxy_port}} = opts) do
|
|||
} #{inspect(error)}"
|
||||
)
|
||||
|
||||
nil
|
||||
error
|
||||
end
|
||||
end
|
||||
|
||||
|
@ -126,7 +126,7 @@ defp do_open(uri, %{proxy: {proxy_type, proxy_host, proxy_port}} = opts) do
|
|||
} #{inspect(error)}"
|
||||
)
|
||||
|
||||
nil
|
||||
error
|
||||
end
|
||||
end
|
||||
|
||||
|
@ -144,7 +144,7 @@ defp do_open(%URI{host: host, port: port} = uri, opts) do
|
|||
}"
|
||||
)
|
||||
|
||||
nil
|
||||
error
|
||||
end
|
||||
end
|
||||
|
||||
|
@ -169,7 +169,7 @@ defp close_least_used_and_do_open(name, uri, opts) do
|
|||
|
||||
do_open(uri, opts)
|
||||
else
|
||||
[] -> nil
|
||||
[] -> {:error, :pool_overflowed}
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue