parent
d26194f62d
commit
90250f5be5
@ -1336,6 +1336,19 @@ func (dc *downstreamConn) handleMessageRegistered(msg *irc.Message) error {
|
||||
})
|
||||
return nil
|
||||
}
|
||||
if entity == serviceNick {
|
||||
dc.SendMessage(&irc.Message{
|
||||
Prefix: dc.srv.prefix(),
|
||||
Command: irc.RPL_WHOREPLY,
|
||||
Params: []string{serviceNick, "*", servicePrefix.User, servicePrefix.Host, dc.srv.Hostname, serviceNick, "H", "0 " + serviceRealname},
|
||||
})
|
||||
dc.SendMessage(&irc.Message{
|
||||
Prefix: dc.srv.prefix(),
|
||||
Command: irc.RPL_ENDOFWHO,
|
||||
Params: []string{dc.nick, serviceNick, "End of /WHO list"},
|
||||
})
|
||||
return nil
|
||||
}
|
||||
|
||||
uc, upstreamName, err := dc.unmarshalEntity(entity)
|
||||
if err != nil {
|
||||
|
@ -27,6 +27,7 @@ import (
|
||||
)
|
||||
|
||||
const serviceNick = "BouncerServ"
|
||||
const serviceRealname = "soju bouncer service"
|
||||
|
||||
var servicePrefix = &irc.Prefix{
|
||||
Name: serviceNick,
|
||||
|
@ -1337,7 +1337,7 @@ func (uc *upstreamConn) handleMessage(msg *irc.Message) error {
|
||||
// Ignore
|
||||
case irc.ERR_PASSWDMISMATCH, irc.ERR_ERRONEUSNICKNAME, irc.ERR_NICKNAMEINUSE, irc.ERR_NICKCOLLISION, irc.ERR_UNAVAILRESOURCE:
|
||||
if !uc.registered {
|
||||
return fmt.Errorf("registration failed: %v", msg.Params[len(msg.Params) - 1])
|
||||
return fmt.Errorf("registration failed: %v", msg.Params[len(msg.Params)-1])
|
||||
}
|
||||
fallthrough
|
||||
default:
|
||||
|
Loading…
Reference in New Issue
Block a user