summaryrefslogtreecommitdiffstats
path: root/gateway/gateway.go
diff options
context:
space:
mode:
authorWim <wim@42.be>2017-08-29 20:28:44 +0200
committerWim <wim@42.be>2017-08-29 20:28:44 +0200
commit2f7df2df432b3619a95e7eb6b3d8e511b105d5cf (patch)
treeff336e650bd8a27e1491e2cd60ab733f806f7dff /gateway/gateway.go
parentad3a753718cb8cff85ebbe06a663a315800db6c8 (diff)
downloadmatterbridge-msglm-2f7df2df432b3619a95e7eb6b3d8e511b105d5cf.tar.gz
matterbridge-msglm-2f7df2df432b3619a95e7eb6b3d8e511b105d5cf.tar.bz2
matterbridge-msglm-2f7df2df432b3619a95e7eb6b3d8e511b105d5cf.zip
Do not add messages without ID to cache
Diffstat (limited to 'gateway/gateway.go')
-rw-r--r--gateway/gateway.go4
1 files changed, 3 insertions, 1 deletions
diff --git a/gateway/gateway.go b/gateway/gateway.go
index aca8ecec..d09741fa 100644
--- a/gateway/gateway.go
+++ b/gateway/gateway.go
@@ -186,7 +186,9 @@ func (gw *Gateway) handleMessage(msg config.Message, dest *bridge.Bridge) []*BrM
fmt.Println(err)
}
// append the message ID (mID) from this bridge (dest) to our brMsgIDs slice
- brMsgIDs = append(brMsgIDs, &BrMsgID{dest, mID})
+ if mID != "" {
+ brMsgIDs = append(brMsgIDs, &BrMsgID{dest, mID})
+ }
}
return brMsgIDs
}