summary refs log tree commit diff
path: root/synapse/api
diff options
context:
space:
mode:
Diffstat (limited to 'synapse/api')
-rw-r--r--synapse/api/auth.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/synapse/api/auth.py b/synapse/api/auth.py

index e9e3279b9a..54ecbe5b3a 100644 --- a/synapse/api/auth.py +++ b/synapse/api/auth.py
@@ -169,6 +169,11 @@ class Auth(object): ) _, kick_level = yield self.store.get_ops_levels(event.room_id) + if kick_level: + kick_level = int(kick_level) + else: + kick_level = 5 + if user_level < kick_level: raise AuthError( 403, "You cannot kick user %s." % target_user_id