Skip to content

Commit

Permalink
Update lib/phoenix_live_view/async_result.ex
Browse files Browse the repository at this point in the history
Co-authored-by: José Valim <[email protected]>
  • Loading branch information
chrismccord and josevalim authored Aug 23, 2023
1 parent aa23281 commit 844e08a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/phoenix_live_view/async_result.ex
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ defmodule Phoenix.LiveView.AsyncResult do
do_reduce(result, acc, fun)
end

def reduce(%AsyncResult{}, acc, _fun), do: acc
def reduce(%AsyncResult{}, {_, acc}, _fun), do: {:done, acc}

defp do_reduce(_list, {:halt, acc}, _fun), do: {:halted, acc}
defp do_reduce(list, {:suspend, acc}, fun), do: {:suspended, acc, &do_reduce(list, &1, fun)}
Expand Down

0 comments on commit 844e08a

Please sign in to comment.