projects
/
akkoma
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Call ConfirmUserPlug from Router, not Endpoint
[akkoma]
/
lib
/
pleroma
/
web
/
plugs
/
set_user_session_id_plug.ex
diff --git
a/lib/pleroma/web/plugs/set_user_session_id_plug.ex
b/lib/pleroma/web/plugs/set_user_session_id_plug.ex
index d2338c03f681c073fde571bf350a556e8a19800f..9f4a6b6acb218d0456fe7638501ab378513886df 100644
(file)
--- a/
lib/pleroma/web/plugs/set_user_session_id_plug.ex
+++ b/
lib/pleroma/web/plugs/set_user_session_id_plug.ex
@@
-3,8
+3,7
@@
# SPDX-License-Identifier: AGPL-3.0-only
defmodule Pleroma.Web.Plugs.SetUserSessionIdPlug do
# SPDX-License-Identifier: AGPL-3.0-only
defmodule Pleroma.Web.Plugs.SetUserSessionIdPlug do
- import Plug.Conn
-
+ alias Pleroma.Helpers.AuthHelper
alias Pleroma.Web.OAuth.Token
def init(opts) do
alias Pleroma.Web.OAuth.Token
def init(opts) do
@@
-12,7
+11,7
@@
defmodule Pleroma.Web.Plugs.SetUserSessionIdPlug do
end
def call(%{assigns: %{token: %Token{} = oauth_token}} = conn, _) do
end
def call(%{assigns: %{token: %Token{} = oauth_token}} = conn, _) do
-
put_session(conn, :oauth_toke
n, oauth_token.token)
+
AuthHelper.put_session_token(con
n, oauth_token.token)
end
def call(conn, _), do: conn
end
def call(conn, _), do: conn