It does take the changeset as a first parameter, it’s just that the pipe removes the need to type it out.
Example:
def sum(a, b) do
a + b
end
# the two lines below do the same thing:
sum(1, 2)
1 |> sum(2)
It does take the changeset as a first parameter, it’s just that the pipe removes the need to type it out.
Example:
def sum(a, b) do
a + b
end
# the two lines below do the same thing:
sum(1, 2)
1 |> sum(2)