diff options
author | Daniel Wagner-Hall <daniel@matrix.org> | 2016-02-15 16:40:22 +0000 |
---|---|---|
committer | Daniel Wagner-Hall <daniel@matrix.org> | 2016-02-15 16:40:22 +0000 |
commit | 1bbb67c452f33d14e1d4c5b51cc1a694de53bbb8 (patch) | |
tree | 1350a55ac78d960fefddec6eff05b7bd81069542 /synapse/handlers/room.py | |
parent | Reuse update_membership from /join (diff) | |
download | synapse-1bbb67c452f33d14e1d4c5b51cc1a694de53bbb8.tar.xz |
Use update_membership to kick guests
Diffstat (limited to 'synapse/handlers/room.py')
-rw-r--r-- | synapse/handlers/room.py | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/synapse/handlers/room.py b/synapse/handlers/room.py index 04916d4e24..8c8bacf5dd 100644 --- a/synapse/handlers/room.py +++ b/synapse/handlers/room.py @@ -404,7 +404,14 @@ class RoomMemberHandler(BaseHandler): @defer.inlineCallbacks def update_membership( - self, requester, target, room_id, action, txn_id=None, room_hosts=None + self, + requester, + target, + room_id, + action, + txn_id=None, + room_hosts=None, + ratelimit=True, ): effective_membership_state = action if action in ["kick", "unban"]: @@ -451,7 +458,7 @@ class RoomMemberHandler(BaseHandler): yield msg_handler.send_event( event, context, - ratelimit=True, + ratelimit=ratelimit, is_guest=requester.is_guest, room_hosts=room_hosts, ) |