From f678aaed8ea87636c34d8c6d2e317cb7534b2d88 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ken-H=C3=A5vard=20Lieng?= Date: Wed, 27 Jan 2016 18:21:36 +0100 Subject: [PATCH] Only use the default password when connecting to the default server --- server/websocket_handler.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/server/websocket_handler.go b/server/websocket_handler.go index a3759a04..56881607 100644 --- a/server/websocket_handler.go +++ b/server/websocket_handler.go @@ -94,10 +94,11 @@ func (h *wsHandler) connect(b []byte) { i := irc.NewClient(data.Nick, data.Username) i.TLS = data.TLS - i.Password = data.Password i.Realname = data.Realname - if data.Password == "" && viper.GetString("defaults.password") != "" { + if data.Password == "" && + viper.GetString("defaults.password") != "" && + data.Server == viper.GetString("defaults.address") { i.Password = viper.GetString("defaults.password") } else { i.Password = data.Password