From e5989adf92cd5ea007b5e7d50580579f8581fee2 Mon Sep 17 00:00:00 2001 From: Wim Date: Tue, 6 Mar 2018 21:34:55 +0100 Subject: Add support for NoSendJoinPart. Closes #382 --- bridge/slack/slack.go | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'bridge/slack') diff --git a/bridge/slack/slack.go b/bridge/slack/slack.go index a42c7e78..7912988e 100644 --- a/bridge/slack/slack.go +++ b/bridge/slack/slack.go @@ -619,6 +619,10 @@ func (b *Bslack) sendWebhook(msg config.Message) (string, error) { // skipMessageEvent skips event that need to be skipped :-) func (b *Bslack) skipMessageEvent(ev *slack.MessageEvent) bool { + if ev.SubType == "channel_leave" || ev.SubType == "channel_join" { + return b.GetBool("nosendjoinpart") + } + // ignore pinned items if ev.SubType == "pinned_item" || ev.SubType == "unpinned_item" { return true -- cgit v1.2.3