Add time tag to echo messages

Closes: https://todo.sr.ht/~emersion/soju/59

git-svn-id: file:///srv/svn/repo/suika/trunk@291 f0ae65fe-ee39-954e-97ec-027ff2717ef4
This commit is contained in:
contact 2020-05-05 14:52:50 +00:00
parent 39348fb8bc
commit b8fccc5356

View File

@ -1361,6 +1361,9 @@ func (dc *downstreamConn) handleMessageRegistered(msg *irc.Message) error {
})
echoMsg := &irc.Message{
Tags: irc.Tags{
"time": irc.TagValue(time.Now().UTC().Format(serverTimeLayout)),
},
Prefix: &irc.Prefix{
Name: uc.nick,
User: uc.username,
@ -1368,7 +1371,6 @@ func (dc *downstreamConn) handleMessageRegistered(msg *irc.Message) error {
Command: "PRIVMSG",
Params: []string{upstreamName, text},
}
uc.produce(upstreamName, echoMsg, dc)
}
case "NOTICE":