fix: properly halt in ets dump_to_native reducer

This commit is contained in:
Zach Daniel 2022-08-22 10:50:24 -04:00
parent 0d518b0057
commit feee4516bc

View file

@ -525,11 +525,12 @@ defmodule Ash.DataLayer.Ets do
{:cont, {:ok, Map.put(attrs, attribute.name, casted_value)}}
:error ->
{:halt,
{:error,
"Failed to dump #{inspect(Map.get(record, attribute.name))} as type #{inspect(attribute.type)}"}
"Failed to dump #{inspect(Map.get(record, attribute.name))} as type #{inspect(attribute.type)}"}}
{:error, error} ->
{:error, error}
{:halt, {:error, error}}
end
end
end)