From 696c51855024fd0bfffe1bec62ae2e4dd29532a1 Mon Sep 17 00:00:00 2001 From: Wim Date: Sun, 27 May 2018 22:14:31 +0200 Subject: [PATCH] Add error message about webhook (slack) --- bridge/slack/slack.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/bridge/slack/slack.go b/bridge/slack/slack.go index 1633d820..58abf48c 100644 --- a/bridge/slack/slack.go +++ b/bridge/slack/slack.go @@ -573,6 +573,10 @@ func (b *Bslack) handleMessageEvent(ev *slack.MessageEvent) (*config.Message, er // Only deleted messages can have a empty username and text if (rmsg.Text == "" || rmsg.Username == "") && ev.SubType != messageDeleted { + // this is probably a webhook we couldn't resolve + if ev.BotID != "" { + return nil, fmt.Errorf("probably an incoming webhook we couldn't resolve (maybe ourselves)") + } return nil, fmt.Errorf("empty message and not a deleted message") }