Store incoming keys in dummy room if not found

This commit is contained in:
Christian Pauly 2020-05-17 08:16:04 +00:00 committed by Sorunome
parent 928b4c1f89
commit f560a43669

View file

@ -1408,6 +1408,7 @@ class Client {
_pendingToDeviceEvents.add(toDeviceEvent); _pendingToDeviceEvents.add(toDeviceEvent);
break; break;
} }
room ??= Room(client: this, id: roomId);
final String sessionId = toDeviceEvent.content['session_id']; final String sessionId = toDeviceEvent.content['session_id'];
if (toDeviceEvent.type == 'm.room_key' && if (toDeviceEvent.type == 'm.room_key' &&
userDeviceKeys.containsKey(toDeviceEvent.sender) && userDeviceKeys.containsKey(toDeviceEvent.sender) &&