1
0
mirror of https://github.com/anope/anope.git synced 2026-06-29 20:46:39 +02:00

Check virtual mode bases better

This commit is contained in:
Adam
2015-01-26 15:10:18 -05:00
parent d324e91520
commit 2264a206d2
2 changed files with 12 additions and 1 deletions
+8 -1
View File
@@ -213,7 +213,7 @@ ChannelModeVirtual<T>::~ChannelModeVirtual()
}
template<typename T>
ChannelMode *ChannelModeVirtual<T>::Wrap(Anope::string &param)
void ChannelModeVirtual<T>::Check()
{
if (basech == NULL)
{
@@ -221,7 +221,11 @@ ChannelMode *ChannelModeVirtual<T>::Wrap(Anope::string &param)
if (basech)
basech->listeners.push_back(this);
}
}
template<typename T>
ChannelMode *ChannelModeVirtual<T>::Wrap(Anope::string &param)
{
return basech;
}
@@ -453,6 +457,9 @@ bool ModeManager::AddChannelMode(ChannelMode *cm)
FOREACH_MOD(OnChannelModeAdd, (cm));
for (unsigned int i = 0; i < ChannelModes.size(); ++i)
ChannelModes[i]->Check();
return true;
}