|
|
@ -241,8 +241,7 @@ func advancedhelpmsg(rtm *slack.RTM, ev *slack.MessageEvent) { |
|
|
|
|
|
|
|
|
|
|
|
func contenthandler(rtm *slack.RTM, ev *slack.MessageEvent, message, queryType string, redisClient *redis.Client) { |
|
|
|
func contenthandler(rtm *slack.RTM, ev *slack.MessageEvent, message, queryType string, redisClient *redis.Client) { |
|
|
|
loreTerm := strings.Replace(message, ".lore", "", -1) |
|
|
|
loreTerm := strings.Replace(message, ".lore", "", -1) |
|
|
|
println("searching for:", loreTerm) |
|
|
|
glogger.Debug.Printf("searching for: %s\n", loreTerm) |
|
|
|
//rtm.SendMessage(rtm.NewOutgoingMessage(fmt.Sprintf("searching for '%s'\n", loreTerm), ev.Channel))
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
content, err := loreCheck(loreTerm, queryType, redisClient) |
|
|
|
content, err := loreCheck(loreTerm, queryType, redisClient) |
|
|
|
if err == nil { |
|
|
|
if err == nil { |
|
|
|