summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWim <wim@42.be>2016-07-11 23:30:42 +0200
committerWim <wim@42.be>2016-07-11 23:30:42 +0200
commitfb586f4a9607ab6848ffe0c16702977637ed203b (patch)
treee471e601705e56ddc9f76ebae81bea401ad2dead
parentced371bece6bcdadba3f61bb70f5f5aa24bc3c23 (diff)
downloadmatterbridge-msglm-fb586f4a9607ab6848ffe0c16702977637ed203b.tar.gz
matterbridge-msglm-fb586f4a9607ab6848ffe0c16702977637ed203b.tar.bz2
matterbridge-msglm-fb586f4a9607ab6848ffe0c16702977637ed203b.zip
Remove Port from IRC config. Specify it with server
-rw-r--r--README.md3
-rw-r--r--bridge/bridge.go5
-rw-r--r--bridge/config.go2
3 files changed, 5 insertions, 5 deletions
diff --git a/README.md b/README.md
index 695be1fb..50bd9c15 100644
--- a/README.md
+++ b/README.md
@@ -56,8 +56,7 @@ Look at matterbridge.conf.sample for an example
```
[IRC]
-server="irc.freenode.net"
-port=6667
+server="irc.freenode.net:6667"
#default no TLS connection to irc server
UseTLS=false
#do not check the certificate if we use TLS (allows for selfsigned certificates)
diff --git a/bridge/bridge.go b/bridge/bridge.go
index 8e2b1393..b6445be2 100644
--- a/bridge/bridge.go
+++ b/bridge/bridge.go
@@ -114,7 +114,10 @@ func (b *Bridge) createIRC(name string) *irc.Connection {
i.Password = b.Config.IRC.Password
}
i.AddCallback(ircm.RPL_WELCOME, b.handleNewConnection)
- i.Connect(b.Config.IRC.Server + ":" + strconv.Itoa(b.Config.IRC.Port))
+ err := i.Connect(b.Config.IRC.Server)
+ if err != nil {
+ flog.irc.Fatal(err)
+ }
return i
}
diff --git a/bridge/config.go b/bridge/config.go
index 37d3e95c..2bec5108 100644
--- a/bridge/config.go
+++ b/bridge/config.go
@@ -11,7 +11,6 @@ type Config struct {
UseTLS bool
SkipTLSVerify bool
Server string
- Port int
Nick string
Password string
Channel string
@@ -22,7 +21,6 @@ type Config struct {
}
Mattermost struct {
URL string
- Port int
ShowJoinPart bool
Token string
IconURL string