mirror of
https://github.com/vector-im/element-web.git
synced 2024-11-16 13:14:58 +08:00
Fix off-by-one error in read-marker advancing
The fix to https://github.com/vector-im/vector-web/issues/1241 introduced an off-by-one error which meant we would show the RM before the last event in a room. We were actually winding the RM back one if the last message wasn't sent by us.
This commit is contained in:
parent
272bef1606
commit
04c9924ad6
@ -392,7 +392,7 @@ var TimelinePanel = React.createClass({
|
||||
|
||||
// now think about advancing it
|
||||
var myUserId = MatrixClientPeg.get().credentials.userId;
|
||||
for (; i < events.length; i++) {
|
||||
for (i++; i < events.length; i++) {
|
||||
var ev = events[i];
|
||||
if (!ev.sender || ev.sender.userId != myUserId) {
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user