mirror of
https://github.com/ergochat/ergo.git
synced 2024-11-22 20:09:41 +01:00
fix behavior of echo-message without message-tags
This commit is contained in:
parent
5892680f60
commit
82732d5b5d
@ -1943,10 +1943,15 @@ func dispatchMessageToTarget(client *Client, tags map[string]string, histType hi
|
||||
|
||||
// the originating session may get an echo message:
|
||||
if rb.session.capabilities.Has(caps.EchoMessage) {
|
||||
if histType == history.Tagmsg && rb.session.capabilities.Has(caps.MessageTags) {
|
||||
hasTagsCap := rb.session.capabilities.Has(caps.MessageTags)
|
||||
if histType == history.Tagmsg && hasTagsCap {
|
||||
rb.AddFromClient(message.Time, message.Msgid, nickMaskString, accountName, tags, command, tnick)
|
||||
} else {
|
||||
rb.AddSplitMessageFromClient(nickMaskString, accountName, tags, command, tnick, message)
|
||||
tagsToSend := tags
|
||||
if !hasTagsCap {
|
||||
tagsToSend = nil
|
||||
}
|
||||
rb.AddSplitMessageFromClient(nickMaskString, accountName, tagsToSend, command, tnick, message)
|
||||
}
|
||||
}
|
||||
if histType != history.Notice && user.Away() {
|
||||
|
Loading…
Reference in New Issue
Block a user