summaryrefslogtreecommitdiff
path: root/ui
diff options
context:
space:
mode:
authorptrcnull <git@ptrcnull.me>2022-04-26 22:07:07 +0200
committerdelthas <delthas@dille.cc>2022-04-27 17:19:22 +0200
commit6866df0720d24a23ecc11b4cb366ad509b2b20d7 (patch)
treeac364a4451f8d268f9ff9e6e68ed1e8d3d95fded /ui
parentShow error when searching if unsupported (diff)
Handle IRC read events correctly
It should mark the buffer as read if the last message was before or at the "read" event, not after.
Diffstat (limited to 'ui')
-rw-r--r--ui/buffers.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/ui/buffers.go b/ui/buffers.go
index b94e21a..db2a462 100644
--- a/ui/buffers.go
+++ b/ui/buffers.go
@@ -430,7 +430,7 @@ func (bs *BufferList) SetRead(netID, title string, timestamp time.Time) {
for i := len(b.lines) - 1; i >= 0; i-- {
line := &b.lines[i]
if line.Readable {
- if line.At.After(timestamp) {
+ if !line.At.After(timestamp) {
b.highlights = 0
b.unread = false
}