summaryrefslogtreecommitdiffstats
path: root/bridge
diff options
context:
space:
mode:
authorWim <wim@42.be>2017-04-16 00:16:24 +0200
committerWim <wim@42.be>2017-04-16 00:16:24 +0200
commit4d2207aba7698fe5ed46c9ad5bc012ee93b68ef5 (patch)
tree94f8851db8f1aef8e2a5aebfacfdb53f5a41ad65 /bridge
parent17b8b86d68badfe27c29c7448548f9eb97dd26e9 (diff)
downloadmatterbridge-msglm-4d2207aba7698fe5ed46c9ad5bc012ee93b68ef5.tar.gz
matterbridge-msglm-4d2207aba7698fe5ed46c9ad5bc012ee93b68ef5.tar.bz2
matterbridge-msglm-4d2207aba7698fe5ed46c9ad5bc012ee93b68ef5.zip
Add support for edited messages (slack)
Diffstat (limited to 'bridge')
-rw-r--r--bridge/slack/slack.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/bridge/slack/slack.go b/bridge/slack/slack.go
index 5de6cf9b..9c9f3fc3 100644
--- a/bridge/slack/slack.go
+++ b/bridge/slack/slack.go
@@ -199,6 +199,11 @@ func (b *Bslack) handleSlackClient(mchan chan *MMMessage) {
// ignore first message
if count > 0 {
flog.Debugf("Receiving from slackclient %#v", ev)
+ if !b.Config.EditDisable && ev.SubMessage != nil {
+ flog.Debugf("SubMessage %#v", ev.SubMessage)
+ ev.User = ev.SubMessage.User
+ ev.Text = ev.SubMessage.Text + b.Config.EditSuffix
+ }
// use our own func because rtm.GetChannelInfo doesn't work for private channels
channel, err := b.getChannelByID(ev.Channel)
if err != nil {