mirror of
https://github.com/vector-im/hydrogen-web.git
synced 2024-12-23 03:25:12 +01:00
add comment why we do things in this order
This commit is contained in:
parent
59bdd2b015
commit
f5acee02be
@ -132,7 +132,10 @@ export class GapWriter {
|
|||||||
return RoomMember.fromMemberEvent(this._roomId, event)?.serialize();
|
return RoomMember.fromMemberEvent(this._roomId, event)?.serialize();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// look into newer events, but using prev_content if found
|
// look into newer events, but using prev_content if found.
|
||||||
|
// We do this before looking into `state` because it is not well specified
|
||||||
|
// in the spec whether the events in there represent state before or after `chunk`.
|
||||||
|
// So we look both directions first in chunk to make sure it doesn't matter.
|
||||||
for (let i = index; i >= 0 && i < events.length; i -= inc) {
|
for (let i = index; i >= 0 && i < events.length; i -= inc) {
|
||||||
const event = events[i];
|
const event = events[i];
|
||||||
if (isOurUser(event)) {
|
if (isOurUser(event)) {
|
||||||
|
Loading…
Reference in New Issue
Block a user