2020-01-26 20:36:50 +00:00
|
|
|
defmodule Mobilizon.Web.Auth.Pipeline do
|
2018-01-14 16:56:50 +00:00
|
|
|
@moduledoc """
|
|
|
|
Handles the app sessions
|
|
|
|
"""
|
2017-12-09 13:58:37 +00:00
|
|
|
|
2018-07-27 08:45:35 +00:00
|
|
|
use Guardian.Plug.Pipeline,
|
2018-10-11 15:37:39 +00:00
|
|
|
otp_app: :mobilizon,
|
2020-01-26 20:36:50 +00:00
|
|
|
module: Mobilizon.Web.Auth.Guardian,
|
|
|
|
error_handler: Mobilizon.Web.Auth.ErrorHandler
|
2017-12-09 13:58:37 +00:00
|
|
|
|
2021-08-02 16:11:22 +00:00
|
|
|
plug(Guardian.Plug.VerifyHeader, scheme: "Bearer")
|
2018-11-06 09:30:27 +00:00
|
|
|
plug(Guardian.Plug.LoadResource, allow_blank: true)
|
2020-01-26 20:36:50 +00:00
|
|
|
plug(Mobilizon.Web.Auth.Context)
|
2018-01-14 16:56:50 +00:00
|
|
|
end
|