diff options
author | Wim <wim@42.be> | 2019-02-10 17:23:50 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-02-10 17:23:50 +0100 |
commit | 57f156be8328529666aadaee780711f12b6e162b (patch) | |
tree | 312da5daceb4f622abb15eaaba505416600f4ae3 /bridge/slack/slack.go | |
parent | 2cfd880cdb0df29771bf8f31df8d990ab897889d (diff) | |
download | matterbridge-msglm-57f156be8328529666aadaee780711f12b6e162b.tar.gz matterbridge-msglm-57f156be8328529666aadaee780711f12b6e162b.tar.bz2 matterbridge-msglm-57f156be8328529666aadaee780711f12b6e162b.zip |
Hint at thread replies when messages are unthreaded (slack) (#684)
Diffstat (limited to 'bridge/slack/slack.go')
-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 001b1268..1685c4fc 100644 --- a/bridge/slack/slack.go +++ b/bridge/slack/slack.go @@ -293,6 +293,12 @@ func (b *Bslack) sendRTM(msg config.Message) (string, error) { return "", err } + // Handle prefix hint for unthreaded messages. + if msg.ParentID == "msg-parent-not-found" { + msg.ParentID = "" + msg.Text = fmt.Sprintf("[thread]: %s", msg.Text) + } + // Handle message deletions. if handled, err = b.deleteMessage(&msg, channelInfo); handled { return msg.ID, err |