review fixes

This commit is contained in:
Shivaram Lingamneni 2019-02-05 04:29:32 -05:00
parent 463de94610
commit a9f9f725b1
3 changed files with 7 additions and 1 deletions

View File

@ -47,6 +47,8 @@ func (rb *ResponseBuffer) Add(tags *map[string]ircmsg.TagValue, prefix string, c
if rb.finalized { if rb.finalized {
rb.target.server.logger.Error("internal", "message added to finalized ResponseBuffer, undefined behavior") rb.target.server.logger.Error("internal", "message added to finalized ResponseBuffer, undefined behavior")
debug.PrintStack() debug.PrintStack()
// TODO(dan): send a NOTICE to the end user with a string representation of the message,
// for debugging purposes
return return
} }

View File

@ -158,7 +158,7 @@ func (server *Server) setISupport() (err error) {
isupport.Add("CASEMAPPING", "ascii") isupport.Add("CASEMAPPING", "ascii")
isupport.Add("CHANMODES", strings.Join([]string{modes.Modes{modes.BanMask, modes.ExceptMask, modes.InviteMask}.String(), "", modes.Modes{modes.UserLimit, modes.Key}.String(), modes.Modes{modes.InviteOnly, modes.Moderated, modes.NoOutside, modes.OpOnlyTopic, modes.ChanRoleplaying, modes.Secret}.String()}, ",")) isupport.Add("CHANMODES", strings.Join([]string{modes.Modes{modes.BanMask, modes.ExceptMask, modes.InviteMask}.String(), "", modes.Modes{modes.UserLimit, modes.Key}.String(), modes.Modes{modes.InviteOnly, modes.Moderated, modes.NoOutside, modes.OpOnlyTopic, modes.ChanRoleplaying, modes.Secret}.String()}, ","))
if config.History.Enabled && config.History.ChathistoryMax > 0 { if config.History.Enabled && config.History.ChathistoryMax > 0 {
isupport.Add("CHATHISTORY", strconv.Itoa(config.History.ChathistoryMax)) isupport.Add("draft/CHATHISTORY", strconv.Itoa(config.History.ChathistoryMax))
} }
isupport.Add("CHANNELLEN", strconv.Itoa(config.Limits.ChannelLen)) isupport.Add("CHANNELLEN", strconv.Itoa(config.Limits.ChannelLen))
isupport.Add("CHANTYPES", "#") isupport.Add("CHANTYPES", "#")

View File

@ -470,6 +470,10 @@ fakelag:
# message history tracking, for the RESUME extension and possibly other uses in future # message history tracking, for the RESUME extension and possibly other uses in future
history: history:
# should we store messages for later playback? # should we store messages for later playback?
# the current implementation stores messages in RAM only; they do not persist
# across server restarts. however, you should disable this unless you understand
# how it interacts with the GDPR and/or any data privacy laws that apply
# in your country and the countries of your users.
enabled: true enabled: true
# how many channel-specific events (messages, joins, parts) should be tracked per channel? # how many channel-specific events (messages, joins, parts) should be tracked per channel?