mirror of
https://github.com/ash-project/ash.git
synced 2024-09-20 05:23:03 +12:00
docs: Update constraints.md (#869)
The username is not an argument, i replaced it with the argument title.
This commit is contained in:
parent
e331e24c7b
commit
f7024f2b6c
1 changed files with 2 additions and 2 deletions
|
@ -139,10 +139,10 @@ defmodule MyProject.MyApi.Account do
|
|||
end
|
||||
|
||||
change fn changeset, _ ->
|
||||
username = Ash.Changeset.get_argument(changeset, :username)
|
||||
title = Ash.Changeset.get_argument(changeset, :title)
|
||||
age = Ash.Changeset.get_argument(changeset, :age)
|
||||
|
||||
Ash.Changeset.change_attribute(changeset, :username, "#{username}-#{age}")
|
||||
Ash.Changeset.change_attribute(changeset, :username, "#{title}-#{age}")
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue