From 9c767cb019e34004a105f5d6f31104fbc7613422 Mon Sep 17 00:00:00 2001 From: Matthew Faltys Date: Tue, 13 Feb 2018 08:39:18 -0600 Subject: [PATCH] Update rng function --- lorebot/lorebot.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lorebot/lorebot.go b/lorebot/lorebot.go index bb89f3e..d3e4f7b 100644 --- a/lorebot/lorebot.go +++ b/lorebot/lorebot.go @@ -207,8 +207,8 @@ func staticCommandHandler(rtm *slack.RTM, ev *slack.MessageEvent, redisClient *r advancedhelpmsg(rtm, ev) case "rng": rnghandler(rtm, ev, redisClient) - case "betarng": - betarnghandler(rtm, ev, redisClient) + case "depricatedrng": + depricatedrnghandler(rtm, ev, redisClient) case "listen": rtm.SendMessage(rtm.NewOutgoingMessage("*it's what you hearin*", ev.Channel)) case "lorelist": @@ -290,7 +290,7 @@ func riphandler(rtm *slack.RTM, ev *slack.MessageEvent, target string) { rtm.SendMessage(rtm.NewOutgoingMessage(ripFmt, ev.Channel)) } -func rnghandler(rtm *slack.RTM, ev *slack.MessageEvent, redisClient *redis.Client) { +func depricatedrnghandler(rtm *slack.RTM, ev *slack.MessageEvent, redisClient *redis.Client) { // get random lore from list rngLore, err := redisClient.SRandMember("index:lore:added").Result() if err != nil { @@ -308,7 +308,7 @@ func rnghandler(rtm *slack.RTM, ev *slack.MessageEvent, redisClient *redis.Clien rtm.SendMessage(rtm.NewOutgoingMessage(rngMsg, ev.Channel)) } -func betarnghandler(rtm *slack.RTM, ev *slack.MessageEvent, redisClient *redis.Client) { +func rnghandler(rtm *slack.RTM, ev *slack.MessageEvent, redisClient *redis.Client) { // aka index:command:added newType := fmt.Sprintf("index:lore:added") //command, err := botfunc.Query(newType, redisClient)