downstream: fix downstream check for draft/read-marker

`dc` is the source connection, `d` is the destination for the
broadcast.

Fixes: 7e21e79eab ("downstream: fix MARKREAD/READ command name in broadcast")
This commit is contained in:
Simon Ser 2022-07-12 17:03:23 +02:00
parent 1e78e3e4b0
commit c69ea81999

View File

@ -3017,7 +3017,7 @@ func (dc *downstreamConn) handleMessageRegistered(ctx context.Context, msg *irc.
network.forEachDownstream(func(d *downstreamConn) {
if broadcast || dc.id == d.id {
cmd := "MARKREAD"
if !dc.caps.IsEnabled("draft/read-marker") {
if !d.caps.IsEnabled("draft/read-marker") {
cmd = "READ"
}
d.SendMessage(&irc.Message{