mirror of
https://github.com/cjdenio/jia.git
synced 2024-11-22 07:33:39 +00:00
debug
This commit is contained in:
parent
a635479dfc
commit
659be30408
1 changed files with 6 additions and 0 deletions
|
@ -97,6 +97,12 @@ func onMessage(slackClient *slack.Client, event *slackevents.MessageEvent) {
|
||||||
}
|
}
|
||||||
lastCountAt := time.Unix(lastCountAtInt, 0)
|
lastCountAt := time.Unix(lastCountAtInt, 0)
|
||||||
|
|
||||||
|
if event.User == "UR6P49Q79" {
|
||||||
|
fmt.Println("Kogbot detected.")
|
||||||
|
fmt.Printf("Time: %v\n", time.Since(lastCountAt).Seconds())
|
||||||
|
fmt.Printf("Contains 69: %v\n", strings.Contains(strconv.Itoa(matchedNumber), "69"))
|
||||||
|
}
|
||||||
|
|
||||||
if event.User == "UR6P49Q79" && time.Since(lastCountAt).Seconds() < 2 && strings.Contains(strconv.Itoa(matchedNumber), "69") {
|
if event.User == "UR6P49Q79" && time.Since(lastCountAt).Seconds() < 2 && strings.Contains(strconv.Itoa(matchedNumber), "69") {
|
||||||
slackClient.AddReaction("bangbang", slack.ItemRef{
|
slackClient.AddReaction("bangbang", slack.ItemRef{
|
||||||
Channel: event.Channel,
|
Channel: event.Channel,
|
||||||
|
|
Loading…
Reference in a new issue