DockYard / valid_field

https://hex.pm/packages/valid_field
MIT License
48 stars 6 forks source link

Support embeds #32

Open zimt28 opened 5 years ago

zimt28 commented 5 years ago

Errors for nested schemas don't get added to changeset.errors but the field in changeset.changes. Because of this, ValidField didn't work for nested schemas. Getting errors from Ecto.Changesets.traverse_errors/2 instead of using changeset.errors fixes this issue (https://github.com/DockYard/valid_field/issues/29).