1
0
Fork 0
forked from External/ergo

Merge pull request #344 from slingamn/history.4

add CHATHISTORY and HISTORY implementations
This commit is contained in:
Daniel Oaks 2019-02-05 22:16:45 +10:00 committed by GitHub
commit 71a33890b8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
12 changed files with 428 additions and 48 deletions

View file

@ -157,6 +157,9 @@ func (server *Server) setISupport() (err error) {
isupport.Add("AWAYLEN", strconv.Itoa(config.Limits.AwayLen))
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()}, ","))
if config.History.Enabled && config.History.ChathistoryMax > 0 {
isupport.Add("draft/CHATHISTORY", strconv.Itoa(config.History.ChathistoryMax))
}
isupport.Add("CHANNELLEN", strconv.Itoa(config.Limits.ChannelLen))
isupport.Add("CHANTYPES", "#")
isupport.Add("ELIST", "U")