doc: added comments and updated to latest ashautentication version and required changes
This commit is contained in:
parent
a6fcaa1640
commit
7bfde5e230
19 changed files with 74 additions and 478 deletions
|
|
@ -11,10 +11,12 @@ defmodule MvWeb.LiveUserAuth do
|
|||
# on_mount {MvWeb.LiveUserAuth, :current_user}
|
||||
def on_mount(:current_user, _params, session, socket) do
|
||||
return_to = session[:return_to]
|
||||
|
||||
socket =
|
||||
socket
|
||||
|> assign(:return_to, return_to)
|
||||
|> AshAuthentication.Phoenix.LiveSession.assign_new_resources(session)
|
||||
|
||||
{:cont, session, socket}
|
||||
end
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue