diff options
author | Wim <wim@42.be> | 2017-05-24 22:10:21 +0200 |
---|---|---|
committer | Wim <wim@42.be> | 2017-05-24 22:10:21 +0200 |
commit | 87229bab13d89d87284993f27a4c5c2afa762aa2 (patch) | |
tree | 62f95c99e6f12df7a26b037c21d7edfcfa3a9641 /gateway/gateway.go | |
parent | f065e9e4d583ca0353dcabf0f10432f7f4c167a3 (diff) | |
download | matterbridge-msglm-87229bab13d89d87284993f27a4c5c2afa762aa2.tar.gz matterbridge-msglm-87229bab13d89d87284993f27a4c5c2afa762aa2.tar.bz2 matterbridge-msglm-87229bab13d89d87284993f27a4c5c2afa762aa2.zip |
Fix sending to different channels on same account (slack). Closes #177
Diffstat (limited to 'gateway/gateway.go')
-rw-r--r-- | gateway/gateway.go | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gateway/gateway.go b/gateway/gateway.go index b550430a..4cf4e0ec 100644 --- a/gateway/gateway.go +++ b/gateway/gateway.go @@ -192,9 +192,10 @@ func (gw *Gateway) handleMessage(msg config.Message, dest *bridge.Bridge) { return } originchannel := msg.Channel + origmsg := msg for _, channel := range gw.DestChannelFunc(&msg, *dest) { // do not send to ourself - if channel.ID == getChannelID(msg) { + if channel.ID == getChannelID(origmsg) { continue } log.Debugf("Sending %#v from %s (%s) to %s (%s)", msg, msg.Account, originchannel, dest.Account, channel.Name) |