diff options
author | Hubert Hirtz <hubert@hirtz.pm> | 2020-10-19 14:19:23 +0200 |
---|---|---|
committer | Hubert Hirtz <hubert@hirtz.pm> | 2020-10-19 14:19:23 +0200 |
commit | 8fb22a1c588e41ac6b83b403d3eedda5c0f57869 (patch) | |
tree | fbc4aee795f37607c4935519ac643a73a733c0b2 /irc/states.go | |
parent | Ensure timestamps from msg.TimeOrNow() are always UTC (diff) |
Show topic changes
Closes #34
Diffstat (limited to 'irc/states.go')
-rw-r--r-- | irc/states.go | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/irc/states.go b/irc/states.go index e560bdf..5502dd0 100644 --- a/irc/states.go +++ b/irc/states.go @@ -780,6 +780,12 @@ func (s *Session) handle(msg Message) (err error) { c.TopicWho = msg.Prefix.Copy() c.TopicTime = msg.TimeOrNow() s.channels[channelCf] = c + s.evts <- TopicChangeEvent{ + User: msg.Prefix.Copy(), + Channel: c.Name, + Topic: c.Topic, + Time: c.TopicTime, + } } case "PRIVMSG", "NOTICE": s.evts <- s.privmsgToEvent(msg) |