Only send JOIN message if we have channels to join
Don't send a JOIN command to upstream server when no channels are configured.
This commit is contained in:
parent
9f40925199
commit
07b4de8a1a
@ -552,6 +552,7 @@ func (uc *upstreamConn) handleMessage(msg *irc.Message) error {
|
||||
dc.updateSupportedCaps()
|
||||
})
|
||||
|
||||
if len(uc.network.channels) > 0 {
|
||||
// TODO: split this into multiple messages if need be
|
||||
var names, keys []string
|
||||
for _, ch := range uc.network.channels {
|
||||
@ -565,6 +566,7 @@ func (uc *upstreamConn) handleMessage(msg *irc.Message) error {
|
||||
strings.Join(keys, ","),
|
||||
},
|
||||
})
|
||||
}
|
||||
case irc.RPL_MYINFO:
|
||||
if err := parseMessageParams(msg, nil, &uc.serverName, nil, &uc.availableUserModes, nil); err != nil {
|
||||
return err
|
||||
|
Loading…
Reference in New Issue
Block a user