1
0
Fork 0
forked from External/ergo

fix the analogous issue for vhosts

This commit is contained in:
Shivaram Lingamneni 2019-12-21 20:26:40 -05:00
parent 25c4eb2996
commit 26ca016c66
2 changed files with 6 additions and 5 deletions

View file

@ -65,8 +65,9 @@ func (am *AccountManager) Initialize(server *Server) {
am.accountToMethod = make(map[string]NickEnforcementMethod)
am.server = server
am.buildNickToAccountIndex(server.Config())
am.initVHostRequestQueue()
config := server.Config()
am.buildNickToAccountIndex(config)
am.initVHostRequestQueue(config)
}
func (am *AccountManager) buildNickToAccountIndex(config *Config) {
@ -135,8 +136,8 @@ func (am *AccountManager) buildNickToAccountIndex(config *Config) {
}
}
func (am *AccountManager) initVHostRequestQueue() {
if !am.server.AccountConfig().VHosts.Enabled {
func (am *AccountManager) initVHostRequestQueue(config *Config) {
if !config.Accounts.VHosts.Enabled {
return
}