commit 7385f53c95b48a3d1037184fb4056bc2a25fa655
Author: Wim <wim@42.be>
Date: Mon Jan 07 00:26:11 2019 +0000
diff --git a/gateway/gateway.go b/gateway/gateway.go
index 732c9bc..6fe1996 100644
--- a/gateway/gateway.go
+++ b/gateway/gateway.go
@@ -16 +17 @@
package gateway
import (
+ "os"
"regexp"
"strings"
"time"
@@ -1386 +13910 @@ func (gw *Gateway) mapChannelConfig(cfg []config.Bridge, direction string) {
if strings.HasPrefix(br.Account, "irc.") {
br.Channel = strings.ToLower(br.Channel)
}
+ if strings.HasPrefix(br.Account, "mattermost.") && strings.HasPrefix(br.Channel, "#") {
+ flog.Errorf("Mattermost channels do not start with a #: remove the # in %s", br.Channel)
+ os.Exit(1)
+ }
ID := br.Channel + br.Account
if _, ok := gw.Channels[ID]; !ok {
channel := &config.ChannelInfo{Name: br.Channel, Direction: direction, ID: ID, Options: br.Options, Account: br.Account,