diff --git a/lib/pow_assent/http_adapter/httpc.ex b/lib/pow_assent/http_adapter/httpc.ex index fd5054b..fb4c400 100644 --- a/lib/pow_assent/http_adapter/httpc.ex +++ b/lib/pow_assent/http_adapter/httpc.ex @@ -80,16 +80,11 @@ defmodule PowAssent.HTTPAdapter.Httpc do defp ssl_opts(url) do %{host: host} = URI.parse(url) - # This will prevent warnings from showing up if :certifi or - # :ssl_verify_hostname isn't available - certifi_mod = :certifi - ssl_verify_hostname_mod = :ssl_verify_hostname - [ verify: :verify_peer, depth: 99, - cacerts: certifi_mod.cacerts(), - verify_fun: {&ssl_verify_hostname_mod.verify_fun/3, check_hostname: to_charlist(host)} + cacerts: :certifi.cacerts(), + verify_fun: {&:ssl_verify_hostname.verify_fun/3, check_hostname: to_charlist(host)} ] end end diff --git a/mix.exs b/mix.exs index 812cb1b..bbc8521 100644 --- a/mix.exs +++ b/mix.exs @@ -19,7 +19,9 @@ defmodule PowAssent.MixProject do # Docs name: "PowAssent", - docs: docs() + docs: docs(), + + xref: [exclude: [Mint.HTTP, :certifi, :ssl_verify_hostname]] ] end