Changeset 176 in code for trunk/upstream.go


Ignore:
Timestamp:
Mar 27, 2020, 11:07:20 PM (5 years ago)
Author:
delthas
Message:

Make upstream.SendMessageLabeled use an uint64 id

This commit is preparatory work for code that will call
SendMessageLabeled with a direct downstream id rather than a
downstreamConnection pointer.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/upstream.go

    r175 r176  
    12281228}
    12291229
    1230 func (uc *upstreamConn) SendMessageLabeled(dc *downstreamConn, msg *irc.Message) {
     1230func (uc *upstreamConn) SendMessageLabeled(downstreamID uint64, msg *irc.Message) {
    12311231        if uc.labelsSupported {
    12321232                if msg.Tags == nil {
    12331233                        msg.Tags = make(map[string]irc.TagValue)
    12341234                }
    1235                 msg.Tags["label"] = irc.TagValue(fmt.Sprintf("sd-%d-%d", dc.id, uc.nextLabelID))
     1235                msg.Tags["label"] = irc.TagValue(fmt.Sprintf("sd-%d-%d", downstreamID, uc.nextLabelID))
    12361236                uc.nextLabelID++
    12371237        }
Note: See TracChangeset for help on using the changeset viewer.