diff options
author | Wim <wim@42.be> | 2017-09-19 22:33:26 +0200 |
---|---|---|
committer | Wim <wim@42.be> | 2017-09-19 22:33:26 +0200 |
commit | 5f14141ec95f2dc964e75a98a6cc0bb7dfdd7e79 (patch) | |
tree | acafcbdd39d28b0b31da3282220b51b12b549472 | |
parent | c088e45d85828966d333211b85f1a250753a9979 (diff) | |
download | matterbridge-msglm-5f14141ec95f2dc964e75a98a6cc0bb7dfdd7e79.tar.gz matterbridge-msglm-5f14141ec95f2dc964e75a98a6cc0bb7dfdd7e79.tar.bz2 matterbridge-msglm-5f14141ec95f2dc964e75a98a6cc0bb7dfdd7e79.zip |
Try to not forward slack unfurls. Closes #266
-rw-r--r-- | bridge/slack/slack.go | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/bridge/slack/slack.go b/bridge/slack/slack.go index c72d223b..0469d7ad 100644 --- a/bridge/slack/slack.go +++ b/bridge/slack/slack.go @@ -287,6 +287,12 @@ func (b *Bslack) handleSlackClient(mchan chan *MMMessage) { flog.Debugf("SubMessage %#v", ev.SubMessage) ev.User = ev.SubMessage.User ev.Text = ev.SubMessage.Text + b.Config.EditSuffix + + // it seems ev.SubMessage.Edited == nil when slack unfurls + // do not forward these messages #266 + if ev.SubMessage.Edited == nil { + continue + } } // use our own func because rtm.GetChannelInfo doesn't work for private channels channel, err := b.getChannelByID(ev.Channel) |