Ecto.Multi.prepend
You're seeing just the function
prepend
, go back to Ecto.Multi module for more information.
Specs
Prepends the second multi to the first one.
All names must be unique between both structures.
Example
iex> lhs = Ecto.Multi.new() |> Ecto.Multi.run(:left, fn _, changes -> {:ok, changes} end)
iex> rhs = Ecto.Multi.new() |> Ecto.Multi.run(:right, fn _, changes -> {:error, changes} end)
iex> Ecto.Multi.prepend(lhs, rhs) |> Ecto.Multi.to_list |> Keyword.keys
[:right, :left]