From ebd57d65c7540f61f7d2eda3e875796c5ab326a5 Mon Sep 17 00:00:00 2001 From: prozacx Date: Sun, 12 Mar 2006 22:22:31 +0000 Subject: [PATCH] Fill in the VHostLoop for both editing and new users git-svn-id: https://znc.svn.sourceforge.net/svnroot/znc/trunk@683 726aef4b-f618-498e-8847-2d620e286838 --- modules/webadmin.cpp | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/modules/webadmin.cpp b/modules/webadmin.cpp index 333179a6..0d8fce36 100644 --- a/modules/webadmin.cpp +++ b/modules/webadmin.cpp @@ -770,18 +770,6 @@ bool CWebAdminSock::UserPage(CString& sPageRet, CUser* pUser) { } } - const VCString& vsVHosts = CZNC::Get().GetVHosts(); - for (unsigned int b = 0; b < vsVHosts.size(); b++) { - const CString& sVHost = vsVHosts[b]; - CTemplate& l = m_Template.AddRow("VHostLoop"); - - l["VHost"] = sVHost; - - if (pUser && pUser->GetVHost() == sVHost) { - l["Checked"] = "true"; - } - } - const vector& Channels = pUser->GetChans(); for (unsigned int c = 0; c < Channels.size(); c++) { CChan* pChan = Channels[c]; @@ -805,6 +793,18 @@ bool CWebAdminSock::UserPage(CString& sPageRet, CUser* pUser) { m_Template["StatusPrefix"] = "*"; } + const VCString& vsVHosts = CZNC::Get().GetVHosts(); + for (unsigned int b = 0; b < vsVHosts.size(); b++) { + const CString& sVHost = vsVHosts[b]; + CTemplate& l = m_Template.AddRow("VHostLoop"); + + l["VHost"] = sVHost; + + if (pUser && pUser->GetVHost() == sVHost) { + l["Checked"] = "true"; + } + } + set ssUserMods; CZNC::Get().GetModules().GetAvailableMods(ssUserMods);