Remove mention on Status and add startup bump check
This commit is contained in:
@ -14,7 +14,7 @@ func status(s *discordgo.Session) {
|
|||||||
defer log.PanicSafe()
|
defer log.PanicSafe()
|
||||||
status := fmt.Sprintf("Uptime: %+v\n", time.Since(startupTime))
|
status := fmt.Sprintf("Uptime: %+v\n", time.Since(startupTime))
|
||||||
status += fmt.Sprintf("Last bump: %+v\n", time.Since(config.BumpTime))
|
status += fmt.Sprintf("Last bump: %+v\n", time.Since(config.BumpTime))
|
||||||
status += fmt.Sprintf("Last bumper: <@%+v>\n", config.LastBumper)
|
status += fmt.Sprintf("Last bumper: <@%+v>\n", userFromID(s, config.LastBumper).Username)
|
||||||
status += fmt.Sprintf("Bump needed: %+v\n", bump)
|
status += fmt.Sprintf("Bump needed: %+v\n", bump)
|
||||||
if len(config.Unverified) > 0 {
|
if len(config.Unverified) > 0 {
|
||||||
status += "Unverified users:\n```"
|
status += "Unverified users:\n```"
|
||||||
|
|||||||
3
main.go
3
main.go
@ -86,6 +86,9 @@ func main() {
|
|||||||
|
|
||||||
log.LogInfo("Thanos is now running. Press CTRL-C to exit.")
|
log.LogInfo("Thanos is now running. Press CTRL-C to exit.")
|
||||||
go purgeTimer(dg)
|
go purgeTimer(dg)
|
||||||
|
if time.Since(config.BumpTime) > 2 * time.Hour {
|
||||||
|
dg.ChannelMessageSend(config.AdminChannel, "!d bump is ready")
|
||||||
|
}
|
||||||
sc := make(chan os.Signal, 1)
|
sc := make(chan os.Signal, 1)
|
||||||
signal.Notify(sc, syscall.SIGINT, syscall.SIGTERM, os.Interrupt, os.Kill)
|
signal.Notify(sc, syscall.SIGINT, syscall.SIGTERM, os.Interrupt, os.Kill)
|
||||||
<-sc
|
<-sc
|
||||||
|
|||||||
Reference in New Issue
Block a user