Ensure we don't crash on empty-string proxy
Some checks are pending
ci/woodpecker/push/woodpecker Pipeline is pending
ci/woodpecker/pr/woodpecker Pipeline is pending

This commit is contained in:
FloatingGhost 2022-11-18 11:10:25 +00:00
parent a76cf80c6d
commit c5d1a21a72

View file

@ -99,6 +99,7 @@ defp proxy_type(_), do: {:error, :unknown}
| {:error, atom()}
| nil
def parse_proxy(nil), do: nil
def parse_proxy(""), do: nil
def parse_proxy(proxy) when is_binary(proxy) do
with %URI{} = uri <- URI.parse(proxy),