fix: when casting atom -> string, stringify it first

*duh*
This commit is contained in:
Zach Daniel 2022-06-03 20:35:36 -04:00
parent 174de6131e
commit a626f8d92d

View file

@ -123,7 +123,7 @@ defmodule Ash.Type.String do
def cast_input(nil, _), do: {:ok, nil} def cast_input(nil, _), do: {:ok, nil}
def cast_input(value, constraints) when is_atom(value) do def cast_input(value, constraints) when is_atom(value) do
cast_input(value, constraints) cast_input(to_string(value), constraints)
end end
def cast_input(value, _) do def cast_input(value, _) do