mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-02 09:56:05 -04:00
Merge branch 'erikj/check_room_exists' into erikj/unfederatable
This commit is contained in:
commit
187320b019
2 changed files with 37 additions and 8 deletions
|
@ -65,6 +65,14 @@ class Auth(object):
|
|||
# FIXME
|
||||
return True
|
||||
|
||||
creation_event = auth_events.get((EventTypes.Create, ""), None)
|
||||
|
||||
if not creation_event:
|
||||
raise SynapseError(
|
||||
403,
|
||||
"Room %r does not exist" % (event.room_id,)
|
||||
)
|
||||
|
||||
creating_domain = RoomID.from_string(event.room_id).domain
|
||||
originating_domain = UserID.from_string(event.sender).domain
|
||||
if creating_domain != originating_domain:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue