4
0
mirror of https://github.com/cwinfo/matterbridge.git synced 2025-07-04 10:07:44 +00:00

Add support for mattermost matterbridge plugin

This commit is contained in:
Wim
2018-11-11 21:56:12 +01:00
parent 2f042ad915
commit 730ccdd456
2 changed files with 10 additions and 3 deletions

View File

@ -321,6 +321,12 @@ func (gw *Gateway) handleMessage(msg config.Message, dest *bridge.Bridge) []*BrM
msg.ParentID = canonicalParentMsgID
}
// if we are using mattermost plugin account, send messages to MattermostPlugin channel
// that can be picked up by the mattermost matterbridge plugin
if dest.Account == "mattermost.plugin" {
gw.Router.MattermostPlugin <- msg
}
mID, err := dest.Send(msg)
if err != nil {
flog.Error(err)