mirror of
https://github.com/cjdenio/jia.git
synced 2025-05-10 23:53:05 +00:00
Merge bc8d295e0c
into 6f1223cd84
This commit is contained in:
commit
a3095f1ea3
1 changed files with 2 additions and 1 deletions
|
@ -10,6 +10,7 @@ import (
|
|||
"strconv"
|
||||
"strings"
|
||||
"time"
|
||||
"strings"
|
||||
|
||||
"github.com/slack-go/slack"
|
||||
"github.com/slack-go/slack/slackevents"
|
||||
|
@ -24,7 +25,7 @@ func HandleInnerEvent(slackClient *slack.Client, innerEvent *slackevents.EventsA
|
|||
|
||||
func onMessage(slackClient *slack.Client, event *slackevents.MessageEvent) {
|
||||
// Ignore messages that aren't in the target channel, or are non-user messages.
|
||||
if event.Channel != jiaConfig.ChannelID || event.User == "USLACKBOT" || event.User == "" {
|
||||
if event.Channel != jiaConfig.ChannelID || event.User == "USLACKBOT" || event.User == "" || strings.HasPrefix(event.Text, "#") {
|
||||
return
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue