Browse Source

Add guildMemberUpdate for when monitorRole is added

hkremer/rebranding
Gregory Rudolph 4 years ago
parent
commit
e316246944
Signed by: rudi
GPG Key ID: EF64F3CBD1A1EBDD
  1. 17
      main.go

17
main.go

@ -163,12 +163,17 @@ func ready(s *discordgo.Session, event *discordgo.Ready) {
s.UpdateStatus(0, "DreamDaddy v0.9") s.UpdateStatus(0, "DreamDaddy v0.9")
} }
//func guildMemberRoleAdd(s *discordgo.Session, m *discordgo.GuildMemberRoleAdd) { func guildMemberUpdate(s *discordgo.Session, m *discordgo.GuildMemberUpdate) {
// defer log.PanicSafe() defer log.PanicSafe()
// config.Unverified[m.User.ID] = time.Now() for role := range m.Roles {
// config.Probations[m.User.ID] = time.Now() if fmt.Sprintf("%+v", role) == config.MonitorRole {
// saveConfig() config.Unverified[m.User.ID] = time.Now()
//} config.Probations[m.User.ID] = time.Now()
saveConfig()
}
}
}
func guildMemberAdd(s *discordgo.Session, m *discordgo.GuildMemberAdd) { func guildMemberAdd(s *discordgo.Session, m *discordgo.GuildMemberAdd) {
defer log.PanicSafe() defer log.PanicSafe()

Loading…
Cancel
Save