ModeHandler::~ModeHandler()
{
- if (ServerInstance && ServerInstance->Modes && ServerInstance->Modes->FindMode(mode, m_type) == this)
- ServerInstance->Logs->Log("MODE", DEFAULT, "ERROR: Destructor for mode %c called while still registered", mode);
}
bool ModeHandler::IsListMode()
bool ModuleManager::Attach(Implementation i, Module* mod)
{
- if (Modules.find(mod->ModuleSourceFile) == Modules.end())
- ServerInstance->Logs->Log("MODULE", DEFAULT, "Module is attaching to hook %d in constructor; this does not handle exceptions correctly!", i);
-
if (std::find(EventHandlers[i].begin(), EventHandlers[i].end(), mod) != EventHandlers[i].end())
return false;
void ModuleManager::AddService(ServiceProvider& item)
{
Module* owner = item.creator;
- if (Modules.find(owner->ModuleSourceFile) == Modules.end())
- ServerInstance->Logs->Log("MODULE", DEFAULT, "Module is registering item %s in constructor; this does not handle exceptions correctly!", item.name.c_str());
switch (item.service)
{