fix double nicks appearing in NAMES output

--HG--
branch : nmdc-ircfrontend
This commit is contained in:
. 2016-05-07 19:49:23 +12:00
parent 89a9664790
commit 6069ad8bd8

View File

@ -474,10 +474,12 @@ func (s *Server) DisconnectClient() {
} }
func (s *Server) sendNames() { func (s *Server) sendNames() {
names := s.upstreamLauncher.Self.Nick names := s.upstreamLauncher.Self.Nick // always include ourselves
if s.upstream != nil { if s.upstream != nil {
for nick, _ := range s.upstream.Users { for nick, _ := range s.upstream.Users {
names += " " + nick if nick != s.upstreamLauncher.Self.Nick { // but don't repeat ourselves
names += " " + nick
}
} }
} }