mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-02 13:46:02 -04:00
Split out the auth handler
This commit is contained in:
parent
07233a1ec8
commit
4a10510cd5
10 changed files with 23 additions and 24 deletions
|
@ -38,7 +38,7 @@ class TokenRefreshRestServlet(RestServlet):
|
|||
body = parse_json_object_from_request(request)
|
||||
try:
|
||||
old_refresh_token = body["refresh_token"]
|
||||
auth_handler = self.hs.get_handlers().auth_handler
|
||||
auth_handler = self.hs.get_auth_handler()
|
||||
(user_id, new_refresh_token) = yield self.store.exchange_refresh_token(
|
||||
old_refresh_token, auth_handler.generate_refresh_token)
|
||||
new_access_token = yield auth_handler.issue_access_token(user_id)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue