mirror of
https://github.com/znc/znc.git
synced 2026-07-05 01:11:53 +02:00
Fix stickychan to work with disabled channels (e.g. after a kick)
This kinda turns stickychan into kickrejoin... well, so what? Thanks to Julian for reporting this. git-svn-id: https://znc.svn.sourceforge.net/svnroot/znc/trunk@1238 726aef4b-f618-498e-8847-2d620e286838
This commit is contained in:
@@ -78,14 +78,17 @@ public:
|
||||
{
|
||||
for (MCString::iterator it = BeginNV(); it != EndNV(); it++)
|
||||
{
|
||||
if (!m_pUser->FindChan(it->first))
|
||||
{
|
||||
CChan *pChan = new CChan(it->first, m_pUser, true);
|
||||
CChan *pChan = m_pUser->FindChan(it->first);
|
||||
if (!pChan) {
|
||||
pChan = new CChan(it->first, m_pUser, true);
|
||||
if (!it->second.empty())
|
||||
pChan->SetKey(it->second);
|
||||
m_pUser->AddChan(pChan);
|
||||
PutModule("Joining [" + it->first + "]");
|
||||
PutIRC("JOIN " + it->first + (it->second.empty() ? "" : it->second));
|
||||
}
|
||||
if (!pChan->IsOn()) {
|
||||
PutModule("Joining [" + pChan->GetName() + "]");
|
||||
PutIRC("JOIN " + pChan->GetName() + (pChan->GetKey().empty()
|
||||
? "" : " " + pChan->GetKey()));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user