mirror of
https://github.com/team-alembic/ash_authentication.git
synced 2024-09-20 13:24:20 +12:00
docs: Update getting-started-with-authentication.md (#244)
Add note for those using policies
This commit is contained in:
parent
42be14d024
commit
a7c296f21a
1 changed files with 14 additions and 0 deletions
|
@ -152,6 +152,13 @@ defmodule MyApp.Accounts.Token do
|
||||||
table "tokens"
|
table "tokens"
|
||||||
repo MyApp.Repo
|
repo MyApp.Repo
|
||||||
end
|
end
|
||||||
|
|
||||||
|
# If using policies, add the following bypass:
|
||||||
|
# policies do
|
||||||
|
# bypass AshAuthentication.Checks.AshAuthenticationInteraction do
|
||||||
|
# authorize_if always()
|
||||||
|
# end
|
||||||
|
# end
|
||||||
end
|
end
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -198,6 +205,13 @@ defmodule MyApp.Accounts.User do
|
||||||
identities do
|
identities do
|
||||||
identity :unique_email, [:email]
|
identity :unique_email, [:email]
|
||||||
end
|
end
|
||||||
|
|
||||||
|
# If using policies, add the folowing bypass:
|
||||||
|
# policies do
|
||||||
|
# bypass AshAuthentication.Checks.AshAuthenticationInteraction do
|
||||||
|
# authorize_if always()
|
||||||
|
# end
|
||||||
|
# end
|
||||||
end
|
end
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue