mod_reload_modules: Be aware of component module (thanks Menel)
Without this, the component module is seen as a module that is loaded
but not configured, and is thus unloaded
--- a/mod_reload_modules/mod_reload_modules.lua Fri May 20 08:41:45 2022 -0400
+++ b/mod_reload_modules/mod_reload_modules.lua Sat May 21 14:48:18 2022 +0200
@@ -8,6 +8,12 @@
return;
end
local configured_modules = module:get_option_inherited_set("modules_enabled", {});
+ local component_module = module:get_option_string("component_module");
+ if component_module then
+ -- Ensure awareness of the component module so that it is not unloaded
+ configured_modules:add(component_module);
+ end
+
-- ignore removed hosts
if not prosody.hosts[module.host] then
module:log("warn", "Ignoring host %s: host was removed...", module.host);