Skip to content

Commit

Permalink
Replace strings by atoms in example app (#3043)
Browse files Browse the repository at this point in the history
  • Loading branch information
Mario Frasca authored and wojtekmach committed Jun 27, 2019
1 parent 1b51027 commit b5b7d3c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion examples/friends/lib/friends/person.ex
Expand Up @@ -9,7 +9,7 @@ defmodule Friends.Person do

def changeset(person, params \\ %{}) do
person
|> Ecto.Changeset.cast(params, ~w(first_name last_name age))
|> Ecto.Changeset.cast(params, [:first_name, :last_name, :age])
|> Ecto.Changeset.validate_required([:first_name, :last_name])
end
end

0 comments on commit b5b7d3c

Please sign in to comment.