diff options
author | Daniel Wagner-Hall <daniel@matrix.org> | 2015-11-05 16:43:19 +0000 |
---|---|---|
committer | Daniel Wagner-Hall <daniel@matrix.org> | 2015-11-05 16:43:19 +0000 |
commit | 2cebe5354504b3baf987c08a5c0098602b38ff84 (patch) | |
tree | 03b35b28adc2f66bd094fe0c52a9f9a2a25b8f46 /synapse/federation/transport/client.py | |
parent | Merge pull request #351 from matrix-org/daniel/fixtox (diff) | |
download | synapse-2cebe5354504b3baf987c08a5c0098602b38ff84.tar.xz |
Exchange 3pid invites for m.room.member invites
Diffstat (limited to 'synapse/federation/transport/client.py')
-rw-r--r-- | synapse/federation/transport/client.py | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/synapse/federation/transport/client.py b/synapse/federation/transport/client.py index a81b3c4345..3d59e1c650 100644 --- a/synapse/federation/transport/client.py +++ b/synapse/federation/transport/client.py @@ -161,7 +161,7 @@ class TransportLayerClient(object): @defer.inlineCallbacks @log_function - def make_membership_event(self, destination, room_id, user_id, membership, args={}): + def make_membership_event(self, destination, room_id, user_id, membership): valid_memberships = {Membership.JOIN, Membership.LEAVE} if membership not in valid_memberships: raise RuntimeError( @@ -173,7 +173,6 @@ class TransportLayerClient(object): content = yield self.client.get_json( destination=destination, path=path, - args=args, retry_on_dns_fail=True, ) @@ -220,6 +219,19 @@ class TransportLayerClient(object): @defer.inlineCallbacks @log_function + def exchange_third_party_invite(self, destination, room_id, event_dict): + path = PREFIX + "/exchange_third_party_invite/%s" % (room_id,) + + response = yield self.client.put_json( + destination=destination, + path=path, + data=event_dict, + ) + + defer.returnValue(response) + + @defer.inlineCallbacks + @log_function def get_event_auth(self, destination, room_id, event_id): path = PREFIX + "/event_auth/%s/%s" % (room_id, event_id) |