Pass server as parameter instead of capturing it in reconnect()
This commit is contained in:
parent
4d8c52fa22
commit
b687c13baa
@ -68,7 +68,7 @@ func reconnect() {
|
|||||||
irc.Password = server.Password
|
irc.Password = server.Password
|
||||||
irc.Realname = server.Realname
|
irc.Realname = server.Realname
|
||||||
|
|
||||||
go func() {
|
go func(server storage.Server) {
|
||||||
err := irc.Connect(server.Address)
|
err := irc.Connect(server.Address)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Println(err)
|
log.Println(err)
|
||||||
@ -85,7 +85,7 @@ func reconnect() {
|
|||||||
}
|
}
|
||||||
irc.Join(joining...)
|
irc.Join(joining...)
|
||||||
}
|
}
|
||||||
}()
|
}(server)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user