mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2024-12-26 22:49:23 -05:00
Fix c+p fail
This commit is contained in:
parent
e1625d62a8
commit
70ecb415f5
@ -530,23 +530,6 @@ class PublicRoomList(BaseFederationServlet):
|
|||||||
data = yield self.room_list_handler.get_public_room_list()
|
data = yield self.room_list_handler.get_public_room_list()
|
||||||
defer.returnValue((200, data))
|
defer.returnValue((200, data))
|
||||||
|
|
||||||
token = parse_string(request, "access_token")
|
|
||||||
if token is None:
|
|
||||||
defer.returnValue((401, {
|
|
||||||
"errcode": "M_MISSING_TOKEN", "error": "Access Token required"
|
|
||||||
}))
|
|
||||||
return
|
|
||||||
|
|
||||||
user_id = yield self.handler.on_openid_userinfo(token)
|
|
||||||
|
|
||||||
if user_id is None:
|
|
||||||
defer.returnValue((401, {
|
|
||||||
"errcode": "M_UNKNOWN_TOKEN",
|
|
||||||
"error": "Access Token unknown or expired"
|
|
||||||
}))
|
|
||||||
|
|
||||||
defer.returnValue((200, {"sub": user_id}))
|
|
||||||
|
|
||||||
# Avoid doing remote HS authorization checks which are done by default by
|
# Avoid doing remote HS authorization checks which are done by default by
|
||||||
# BaseFederationServlet.
|
# BaseFederationServlet.
|
||||||
def _wrap(self, code):
|
def _wrap(self, code):
|
||||||
|
Loading…
Reference in New Issue
Block a user