forked from External/ergo
Ignore non-privmsg commands to services.
This avoids "No such nick" responses to +draft/typing TAGMSG, etc.
This commit is contained in:
parent
9a555f6f30
commit
b7c9fb56c2
1 changed files with 11 additions and 4 deletions
|
|
@ -1906,18 +1906,25 @@ func dispatchMessageToTarget(client *Client, tags map[string]string, histType hi
|
|||
}
|
||||
channel.SendSplitMessage(command, lowestPrefix, tags, client, message, rb)
|
||||
} else {
|
||||
// NOTICE and TAGMSG to services are ignored
|
||||
lowercaseTarget := strings.ToLower(target)
|
||||
service, isService := OragonoServices[lowercaseTarget]
|
||||
_, isZNC := zncHandlers[lowercaseTarget]
|
||||
|
||||
if histType == history.Privmsg {
|
||||
lowercaseTarget := strings.ToLower(target)
|
||||
if service, isService := OragonoServices[lowercaseTarget]; isService {
|
||||
if isService {
|
||||
servicePrivmsgHandler(service, server, client, message.Message, rb)
|
||||
return
|
||||
} else if _, isZNC := zncHandlers[lowercaseTarget]; isZNC {
|
||||
} else if isZNC {
|
||||
zncPrivmsgHandler(client, lowercaseTarget, message.Message, rb)
|
||||
return
|
||||
}
|
||||
}
|
||||
|
||||
// NOTICE and TAGMSG to services are ignored
|
||||
if isService || isZNC {
|
||||
return
|
||||
}
|
||||
|
||||
user := server.clients.Get(target)
|
||||
if user == nil {
|
||||
if histType != history.Notice {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue