~emersion/soju

e4d2ddb377b63f24431fcf48b66bdf19f9b33821 — Hubert Hirtz 12 days ago 88d241f
Don't send TAGMSG to upstreams that don't support it

TAGMSG are (in current specs and drafts from IRCv3) only used for
client tags. These are optional information by design (since they are
not distributed to all users), therefore it is preferable to discard
them accordingly to upstream, instead of waiting for all upstreams to
support the capability to advertise it.
1 files changed, 3 insertions(+), 0 deletions(-)

M downstream.go
M downstream.go => downstream.go +3 -0
@@ 1553,6 1553,9 @@ func (dc *downstreamConn) handleMessageRegistered(msg *irc.Message) error {
			if err != nil {
				return err
			}
			if _, ok := uc.caps["message-tags"]; !ok {
				continue
			}

			uc.SendMessageLabeled(dc.id, &irc.Message{
				Tags:    tags,