diff options
author | Wim <wim@42.be> | 2018-11-19 21:28:23 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-11-19 21:28:23 +0100 |
commit | ae32bae791e6276b4404d6cb19993c3acf543566 (patch) | |
tree | 8a85a5c58fc41138dcf0aa72f95f62d9dd8782a8 /bridge/slack/helpers.go | |
parent | 57eba77561e7b6ab5fbaaa799b45078b62c9c808 (diff) | |
download | matterbridge-msglm-ae32bae791e6276b4404d6cb19993c3acf543566.tar.gz matterbridge-msglm-ae32bae791e6276b4404d6cb19993c3acf543566.tar.bz2 matterbridge-msglm-ae32bae791e6276b4404d6cb19993c3acf543566.zip |
Add protocol to msg.ID in cache (#596)
Diffstat (limited to 'bridge/slack/helpers.go')
-rw-r--r-- | bridge/slack/helpers.go | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/bridge/slack/helpers.go b/bridge/slack/helpers.go index 861a8758..b0fdaba1 100644 --- a/bridge/slack/helpers.go +++ b/bridge/slack/helpers.go @@ -173,9 +173,10 @@ func (b *Bslack) populateReceivedMessage(ev *slack.MessageEvent) (*config.Messag Text: ev.Text, Channel: channel.Name, Account: b.Account, - ID: "slack " + ev.Timestamp, + ID: ev.Timestamp, Extra: make(map[string][]interface{}), ParentID: ev.ThreadTimestamp, + Protocol: b.Protocol, } if b.useChannelID { rmsg.Channel = "ID:" + channel.ID @@ -183,7 +184,7 @@ func (b *Bslack) populateReceivedMessage(ev *slack.MessageEvent) (*config.Messag // Handle 'edit' messages. if ev.SubMessage != nil && !b.GetBool(editDisableConfig) { - rmsg.ID = "slack " + ev.SubMessage.Timestamp + rmsg.ID = ev.SubMessage.Timestamp if ev.SubMessage.ThreadTimestamp != ev.SubMessage.Timestamp { b.Log.Debugf("SubMessage %#v", ev.SubMessage) rmsg.Text = ev.SubMessage.Text + b.GetString(editSuffixConfig) |