From b6433f5df043e366fcf1e2cda20a3bec71020851 Mon Sep 17 00:00:00 2001 From: Cristina Marques Date: Wed, 4 May 2022 18:05:20 +0200 Subject: [PATCH] Fix Credential struct name 5_ecto_associations struct should be "Credential" and not "Credentials" --- phoenix-framework/02-CRUD/guide/5_ecto_associations.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/phoenix-framework/02-CRUD/guide/5_ecto_associations.md b/phoenix-framework/02-CRUD/guide/5_ecto_associations.md index eabe811..3be94fb 100644 --- a/phoenix-framework/02-CRUD/guide/5_ecto_associations.md +++ b/phoenix-framework/02-CRUD/guide/5_ecto_associations.md @@ -229,7 +229,7 @@ Besides creating the associations in the migrations and schema's we also need a 1. Using `put_assoc/3` if the associated entry does already exist in the database. _(not implemented in the demo)_ ```Elixir @doc false - def changeset(user, attrs, %Credentials{} = credentials) do + def changeset(user, attrs, %Credential{} = credentials) do user |> cast(attrs, [:name, :age]) |> validate_required([:name, :age])