summary refs log tree commit diff
path: root/synapse
diff options
context:
space:
mode:
Diffstat (limited to 'synapse')
-rw-r--r--synapse/handlers/room.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/synapse/handlers/room.py b/synapse/handlers/room.py
index 3bfba6c744..626c9f9166 100644
--- a/synapse/handlers/room.py
+++ b/synapse/handlers/room.py
@@ -266,7 +266,7 @@ class RoomCreationHandler(BaseHandler):
             user_id,
         )
 
-        if user_account_data:
+        if user_account_data and "m.direct" in user_account_data[0]:
             direct_rooms = user_account_data[0]["m.direct"]
             # Check if this room was a DM
             if old_room_id in direct_rooms[user_id]: