forked from mystiq/hydrogen-web
there might not be a member yet
This commit is contained in:
parent
7bba83aa9e
commit
5a8aac57ac
1 changed files with 1 additions and 1 deletions
|
@ -107,7 +107,7 @@ export class SyncWriter {
|
||||||
if (trackNewlyJoined) {
|
if (trackNewlyJoined) {
|
||||||
const existingMemberData = await txn.roomMembers.get(this._roomId, userId);
|
const existingMemberData = await txn.roomMembers.get(this._roomId, userId);
|
||||||
// mark new members so we know who needs our the room key for our outbound megolm session
|
// mark new members so we know who needs our the room key for our outbound megolm session
|
||||||
member.needsRoomKey = existingMemberData.needsRoomKey || memberChange.hasJoined;
|
member.needsRoomKey = existingMemberData?.needsRoomKey || memberChange.hasJoined;
|
||||||
}
|
}
|
||||||
txn.roomMembers.set(member.serialize());
|
txn.roomMembers.set(member.serialize());
|
||||||
return memberChange;
|
return memberChange;
|
||||||
|
|
Loading…
Reference in a new issue