mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2024-12-26 15:49:40 -05:00
Merge pull request #1986 from matrix-org/matthew/enable_guest_3p
enable guest access for the 3pl/3pid APIs
This commit is contained in:
commit
2a06b44be2
@ -36,7 +36,7 @@ class ThirdPartyProtocolsServlet(RestServlet):
|
|||||||
|
|
||||||
@defer.inlineCallbacks
|
@defer.inlineCallbacks
|
||||||
def on_GET(self, request):
|
def on_GET(self, request):
|
||||||
yield self.auth.get_user_by_req(request)
|
yield self.auth.get_user_by_req(request, allow_guest=True)
|
||||||
|
|
||||||
protocols = yield self.appservice_handler.get_3pe_protocols()
|
protocols = yield self.appservice_handler.get_3pe_protocols()
|
||||||
defer.returnValue((200, protocols))
|
defer.returnValue((200, protocols))
|
||||||
@ -54,7 +54,7 @@ class ThirdPartyProtocolServlet(RestServlet):
|
|||||||
|
|
||||||
@defer.inlineCallbacks
|
@defer.inlineCallbacks
|
||||||
def on_GET(self, request, protocol):
|
def on_GET(self, request, protocol):
|
||||||
yield self.auth.get_user_by_req(request)
|
yield self.auth.get_user_by_req(request, allow_guest=True)
|
||||||
|
|
||||||
protocols = yield self.appservice_handler.get_3pe_protocols(
|
protocols = yield self.appservice_handler.get_3pe_protocols(
|
||||||
only_protocol=protocol,
|
only_protocol=protocol,
|
||||||
@ -77,7 +77,7 @@ class ThirdPartyUserServlet(RestServlet):
|
|||||||
|
|
||||||
@defer.inlineCallbacks
|
@defer.inlineCallbacks
|
||||||
def on_GET(self, request, protocol):
|
def on_GET(self, request, protocol):
|
||||||
yield self.auth.get_user_by_req(request)
|
yield self.auth.get_user_by_req(request, allow_guest=True)
|
||||||
|
|
||||||
fields = request.args
|
fields = request.args
|
||||||
fields.pop("access_token", None)
|
fields.pop("access_token", None)
|
||||||
@ -101,7 +101,7 @@ class ThirdPartyLocationServlet(RestServlet):
|
|||||||
|
|
||||||
@defer.inlineCallbacks
|
@defer.inlineCallbacks
|
||||||
def on_GET(self, request, protocol):
|
def on_GET(self, request, protocol):
|
||||||
yield self.auth.get_user_by_req(request)
|
yield self.auth.get_user_by_req(request, allow_guest=True)
|
||||||
|
|
||||||
fields = request.args
|
fields = request.args
|
||||||
fields.pop("access_token", None)
|
fields.pop("access_token", None)
|
||||||
|
Loading…
Reference in New Issue
Block a user