Skip to content

Commit

Permalink
Handle IRC read events correctly
Browse files Browse the repository at this point in the history
It should mark the buffer as read if the last message was
before or at the "read" event, not after.
  • Loading branch information
ptrcnull authored and delthas committed Apr 27, 2022
1 parent 9bd580f commit 6866df0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ui/buffers.go
Original file line number Diff line number Diff line change
Expand Up @@ -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
}
Expand Down

0 comments on commit 6866df0

Please sign in to comment.