From b44088aed23eed5d2a6ddc4817e2e550cc9b2b1e Mon Sep 17 00:00:00 2001 From: Kian-Meng Ang Date: Thu, 17 Oct 2024 17:35:46 +0800 Subject: [PATCH] Fix map.field notation warning on Elixir 1.17 (#180) See https://hexdocs.pm/ecto/Ecto.Type.html#c:type/0 --- lib/phoenix_ecto/html.ex | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/phoenix_ecto/html.ex b/lib/phoenix_ecto/html.ex index eb7b269..6688f1a 100644 --- a/lib/phoenix_ecto/html.ex +++ b/lib/phoenix_ecto/html.ex @@ -130,7 +130,7 @@ if Code.ensure_loaded?(Phoenix.HTML) do def input_type(%{types: types}, _, field) do type = Map.get(types, field, :string) - type = if Ecto.Type.primitive?(type), do: type, else: type.type + type = if Ecto.Type.primitive?(type), do: type, else: type.type() case type do :integer -> :number_input