mirror of
https://github.com/element-hq/synapse.git
synced 2026-10-23 00:03:16 +00:00
Add missing None check
This commit is contained in:
1 parent
2bca242fdc
commit
e549aac127
1 file changed
+1
-1
+1
-1
@@ -155,7 +155,7 @@ class Auth(object):
|
||||
# Get room creation event:
|
||||
key = (RoomCreateEvent.TYPE, "", )
|
||||
create = event.old_state_events.get(key)
|
||||
if event.prev_events[0][0] == create.event_id:
|
||||
if create and event.prev_events[0][0] == create.event_id:
|
||||
if create.content["creator"] == event.state_key:
|
||||
return True
|
||||
|
||||
|
||||
Reference in new issue
Block a user