4
0
mirror of https://github.com/cwinfo/matterbridge.git synced 2025-06-26 16:39:24 +00:00
This commit is contained in:
Wim
2017-03-28 23:56:58 +02:00
parent 02d7e2db65
commit 2e4d58cb92
4 changed files with 73 additions and 92 deletions

View File

@ -41,9 +41,11 @@ func (sgw *SameChannelGateway) validChannel(channel string) bool {
return false
}
func (sgw *SameChannelGateway) getDestChannel(msg *config.Message, dest string) []string {
func (sgw *SameChannelGateway) getDestChannel(msg *config.Message, dest string) []config.ChannelInfo {
var channels []config.ChannelInfo
if sgw.validChannel(msg.Channel) {
return []string{msg.Channel}
channels = append(channels, config.ChannelInfo{Name: msg.Channel, Account: dest, ID: msg.Channel + dest})
return channels
}
return []string{}
return channels
}