summary refs log tree commit diff
path: root/synapse/handlers/room_member.py
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2017-03-13 09:59:54 +0000
committerErik Johnston <erik@matrix.org>2017-03-13 09:59:54 +0000
commit672dcf59d3f9da12da43a77e316e2eec76d3ee4c (patch)
tree9186644b06ef01e609ca018e02100ceecf0f3ea4 /synapse/handlers/room_member.py
parentMerge tag 'v0.19.3-rc1' into release-v0.19.3 (diff)
parentRevert "Support registration & login with phone number" (diff)
downloadsynapse-672dcf59d3f9da12da43a77e316e2eec76d3ee4c.tar.xz
Merge branch 'develop' of github.com:matrix-org/synapse into release-v0.19.3
Diffstat (limited to 'synapse/handlers/room_member.py')
-rw-r--r--synapse/handlers/room_member.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/synapse/handlers/room_member.py b/synapse/handlers/room_member.py
index b2806555cf..2052d6d05f 100644
--- a/synapse/handlers/room_member.py
+++ b/synapse/handlers/room_member.py
@@ -719,7 +719,9 @@ class RoomMemberHandler(BaseHandler):
         )
         membership = member.membership if member else None
 
-        if membership is not None and membership != Membership.LEAVE:
+        if membership is not None and membership not in [
+            Membership.LEAVE, Membership.BAN
+        ]:
             raise SynapseError(400, "User %s in room %s" % (
                 user_id, room_id
             ))