mirror of
https://github.com/vector-im/element-web.git
synced 2024-11-16 13:14:58 +08:00
fix InviteDialog crash
This commit is contained in:
parent
76293970f4
commit
71a9fef491
@ -349,7 +349,7 @@ export default class InviteDialog extends React.PureComponent {
|
||||
|
||||
// Also pull in all the rooms tagged as DefaultTagID.DM so we don't miss anything. Sometimes the
|
||||
// room list doesn't tag the room for the DMRoomMap, but does for the room list.
|
||||
const dmTaggedRooms = RoomListStore.instance.orderedLists[DefaultTagID.DM];
|
||||
const dmTaggedRooms = RoomListStore.instance.orderedLists[DefaultTagID.DM] || [];
|
||||
const myUserId = MatrixClientPeg.get().getUserId();
|
||||
for (const dmRoom of dmTaggedRooms) {
|
||||
const otherMembers = dmRoom.getJoinedMembers().filter(u => u.userId !== myUserId);
|
||||
|
Loading…
Reference in New Issue
Block a user