+5
CHANGELOG.md
+5
CHANGELOG.md
+1
-1
examples/oauth.ex
+1
-1
examples/oauth.ex
+2
-2
lib/atex/xrpc/oauth_client.ex
+2
-2
lib/atex/xrpc/oauth_client.ex
···
79
79
Ideally should be called at the end of routes where XRPC calls occur, in case
80
80
the client has transparently refreshed, so that the user is always up to date.
81
81
"""
82
-
@spec update_plug(Plug.Conn.t(), t()) :: Plug.Conn.t()
83
-
def update_plug(%Plug.Conn{} = conn, %__MODULE__{} = client) do
82
+
@spec update_conn(Plug.Conn.t(), t()) :: Plug.Conn.t()
83
+
def update_conn(%Plug.Conn{} = conn, %__MODULE__{} = client) do
84
84
Plug.Conn.put_session(conn, :atex_oauth, %{
85
85
access_token: client.access_token,
86
86
refresh_token: client.refresh_token,