4
0
mirror of https://github.com/cwinfo/matterbridge.git synced 2025-06-26 07:29:24 +00:00

Sync channel topics between Slack bridges (#585)

Added logic to allow for configurable synchronisation of topics and purposes of channels between Slack bridges.
This commit is contained in:
Patrick Connolly
2018-11-26 17:47:04 +08:00
committed by Duco van Amstel
parent 5ed7abdbeb
commit f5659d455d
7 changed files with 123 additions and 9 deletions

View File

@ -267,8 +267,10 @@ func (gw *Gateway) handleMessage(msg config.Message, dest *bridge.Bridge) []*BrM
return brMsgIDs
}
// only relay topic change when configured
if msg.Event == config.EventTopicChange && !gw.Bridges[dest.Account].GetBool("ShowTopicChange") {
// only relay topic change when used in some way on other side
if msg.Event == config.EventTopicChange &&
!gw.Bridges[dest.Account].GetBool("ShowTopicChange") &&
!gw.Bridges[dest.Account].GetBool("SyncTopic") {
return brMsgIDs
}