From 20e4f758742bde9501c6f1549e8cb36798289498 Mon Sep 17 00:00:00 2001 From: "Haelwenn (lanodan) Monnier" Date: Mon, 7 Mar 2022 15:04:04 +0100 Subject: [PATCH] builder.ex: Use Enum.map_join instead of Enum.map+Enum.join --- lib/linkify/builder.ex | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/lib/linkify/builder.ex b/lib/linkify/builder.ex index 0ce3661..e15be81 100644 --- a/lib/linkify/builder.ex +++ b/lib/linkify/builder.ex @@ -66,8 +66,7 @@ defmodule Linkify.Builder do defp format_attrs(attrs) do attrs - |> Enum.map(fn {key, value} -> ~s(#{key}="#{value}") end) - |> Enum.join(" ") + |> Enum.map_join(" ", fn {key, value} -> ~s(#{key}="#{value}") end) end defp truncate(url, false), do: url