diff --git a/lib/auto_linker/parser.ex b/lib/auto_linker/parser.ex index defb590..739173f 100644 --- a/lib/auto_linker/parser.ex +++ b/lib/auto_linker/parser.ex @@ -273,13 +273,13 @@ defmodule AutoLinker.Parser do end defp parse_link(str, %{scheme: true}) do - Regex.run(@match_scheme, str, capture: [:url]) |> hd() + @match_scheme |> Regex.run(str, capture: [:url]) |> hd() end defp parse_link(str, _), do: str defp strip_parens("(" <> buffer) do - Regex.run(~r/[^\)]*/, buffer) |> hd() + ~r/[^\)]*/ |> Regex.run(buffer) |> hd() end defp strip_parens(buffer), do: buffer