From 1a37055fc34349c7ee1b9ea0eaf7158fdeb4bed2 Mon Sep 17 00:00:00 2001 From: "J. Ryan Stinnett" Date: Fri, 24 May 2019 12:03:52 +0100 Subject: [PATCH] Fix comments in unread room tracking A few comments mention read marker where they really mean read receipt. --- src/Unread.js | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/Unread.js b/src/Unread.js index 9514ec821b..ce6784dc58 100644 --- a/src/Unread.js +++ b/src/Unread.js @@ -70,20 +70,20 @@ module.exports = { const ev = room.timeline[i]; if (ev.getId() == readUpToId) { - // If we've read up to this event, there's nothing more recents + // If we've read up to this event, there's nothing more recent // that counts and we can stop looking because the user's read // this and everything before. return false; } else if (!shouldHideEvent(ev) && this.eventTriggersUnreadCount(ev)) { // We've found a message that counts before we hit - // the read marker, so this room is definitely unread. + // the user's read receipt, so this room is definitely unread. return true; } } - // If we got here, we didn't find a message that counted but didn't - // find the read marker either, so we guess and say that the room - // is unread on the theory that false positives are better than - // false negatives here. + // If we got here, we didn't find a message that counted but didn't find + // the user's read receipt either, so we guess and say that the room is + // unread on the theory that false positives are better than false + // negatives here. return true; }, };