mirror of
https://github.com/vector-im/element-web.git
synced 2025-10-11 23:41:04 +02:00
Fix last-spoke order
Turns out this timeline is the other way around, so loop through the other way
This commit is contained in:
parent
2ce521fe38
commit
f1d72296b7
@ -118,8 +118,7 @@ MemberEntry.fromMemberList = function(room, members) {
|
|||||||
// each member last spoke
|
// each member last spoke
|
||||||
const lastSpoke = {};
|
const lastSpoke = {};
|
||||||
const timelineEvents = room.getLiveTimeline().getEvents();
|
const timelineEvents = room.getLiveTimeline().getEvents();
|
||||||
for (var i = timelineEvents.length - 1; i >= 0; --i) {
|
for (const ev of room.getLiveTimeline().getEvents()) {
|
||||||
const ev = timelineEvents[i];
|
|
||||||
lastSpoke[ev.getSender()] = ev.getTs();
|
lastSpoke[ev.getSender()] = ev.getTs();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -360,6 +360,10 @@ module.exports = React.createClass({
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// update ther tab complete list as it depends on who most recently spoke,
|
||||||
|
// and that has probably just changed
|
||||||
|
this._updateTabCompleteList();
|
||||||
},
|
},
|
||||||
|
|
||||||
// called when state.room is first initialised (either at initial load,
|
// called when state.room is first initialised (either at initial load,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user