check if invited user is an admin before rejecting instead
i think this makes more sense tbh than what synapse does Signed-off-by: strawberry <strawberry@puppygock.gay>
This commit is contained in:
parent
34e8fd38cf
commit
608aa83ed2
4 changed files with 16 additions and 12 deletions
|
@ -201,7 +201,9 @@ pub async fn invite_user_route(
|
|||
));
|
||||
}
|
||||
|
||||
if services().rooms.metadata.is_banned(&body.room_id)? && !services().users.is_admin(sender_user)? {
|
||||
if services().rooms.metadata.is_banned(&body.room_id)?
|
||||
&& !services().users.is_admin(sender_user)?
|
||||
{
|
||||
info!(
|
||||
"Local user {} who is not an admin attempted to send an invite for banned room {}.",
|
||||
&sender_user, &body.room_id
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue