From 5f6bf286847550f386324e1e2db6c909cbd9f318 Mon Sep 17 00:00:00 2001 From: Sadie Powell Date: Mon, 4 Mar 2024 13:18:04 +0000 Subject: Rename some of the Module member variables. --- src/modules.cpp | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'src/modules.cpp') diff --git a/src/modules.cpp b/src/modules.cpp index 314a9be37..337eebbb8 100644 --- a/src/modules.cpp +++ b/src/modules.cpp @@ -55,10 +55,10 @@ Module::Module(int mprops, const std::string& mdesc) Cullable::Result Module::Cull() { - if (ModuleDLLManager) + if (ModuleDLL) { - ServerInstance->GlobalCulls.AddItem(ModuleDLLManager); - ModuleDLLManager = nullptr; + ServerInstance->GlobalCulls.AddItem(ModuleDLL); + ModuleDLL = nullptr; } return Cullable::Cull(); } @@ -384,11 +384,11 @@ bool ModuleManager::PrioritizeHooks() bool ModuleManager::CanUnload(Module* mod) { - std::map::iterator modfind = Modules.find(mod->ModuleSourceFile); + std::map::iterator modfind = Modules.find(mod->ModuleFile); if ((modfind == Modules.end()) || (modfind->second != mod) || (mod->dying)) { - LastModuleError = "Module " + mod->ModuleSourceFile + " is not loaded, cannot unload it!"; + LastModuleError = "Module " + mod->ModuleFile + " is not loaded, cannot unload it!"; ServerInstance->Logs.Critical("MODULE", LastModuleError); return false; } @@ -416,7 +416,7 @@ void ModuleManager::DoSafeUnload(Module* mod) // i.e. before we unregister the services of the module being unloaded FOREACH_MOD(OnUnloadModule, (mod)); - std::map::iterator modfind = Modules.find(mod->ModuleSourceFile); + std::map::iterator modfind = Modules.find(mod->ModuleFile); // Unregister modes before extensions because modes may require their extension to show the mode being unset UnregisterModes(mod, MODETYPE_USER); @@ -466,7 +466,7 @@ void ModuleManager::DoSafeUnload(Module* mod) Modules.erase(modfind); ServerInstance->GlobalCulls.AddItem(mod); - ServerInstance->Logs.Normal("MODULE", "The {} module was unloaded", mod->ModuleSourceFile); + ServerInstance->Logs.Normal("MODULE", "The {} module was unloaded", mod->ModuleFile); } void ModuleManager::UnloadAll() @@ -606,7 +606,7 @@ void ModuleManager::AddServices(const ServiceList& list) void ModuleManager::AddService(ServiceProvider& item) { ServerInstance->Logs.Debug("SERVICE", "Adding {} {} provided by {}", item.name, - item.GetTypeString(), item.creator ? item.creator->ModuleSourceFile : "the core"); + item.GetTypeString(), item.creator ? item.creator->ModuleFile : "the core"); switch (item.service) { case SERVICE_DATA: @@ -636,7 +636,7 @@ void ModuleManager::AddService(ServiceProvider& item) void ModuleManager::DelService(ServiceProvider& item) { ServerInstance->Logs.Debug("SERVICE", "Deleting {} {} provided by {}", item.name, - item.GetTypeString(), item.creator ? item.creator->ModuleSourceFile : "the core"); + item.GetTypeString(), item.creator ? item.creator->ModuleFile : "the core"); switch (item.service) { case SERVICE_MODE: -- cgit v1.3.1-10-gc9f91