4
0
mirror of https://github.com/cwinfo/matterbridge.git synced 2025-06-26 01:49:22 +00:00

Add threading support with token (discord) (#1342)

Webhooks don't support the threading yet, so this is token only.
In discord you can reply on each message of a thread, but this is not possible in mattermost (so some changes added there to make sure we always answer on the rootID of the thread).

Also needs some more testing with slack.

update : It now also uses the token when replying to a thread (even if webhooks are enabled), until webhooks have support for threads.
This commit is contained in:
Wim
2020-12-31 16:59:47 +01:00
committed by GitHub
parent b89102c5fc
commit 19d47784bd
5 changed files with 31 additions and 4 deletions

View File

@ -160,7 +160,7 @@ func (r *Router) handleReceive() {
// For some bridges we always add/update the message ID.
// This is necessary as msgIDs will change if a bridge returns
// a different ID in response to edits.
if !exists || msg.Protocol == "discord" {
if !exists {
gw.Messages.Add(msg.Protocol+" "+msg.ID, msgIDs)
}
}