doorman v0.0.4 Doorman.Login.Session

Summary

Functions

Returns the current user or nil based on :user_id in the session

Logs in given user by setting :user_id on the session of passed in conn

Logs out current user

Functions

get_current_user(conn)

Returns the current user or nil based on :user_id in the session.

login(conn, user)

Logs in given user by setting :user_id on the session of passed in conn.

logout(conn)

Logs out current user.