# HG changeset patch # User Matthew Wild # Date 1335034830 -3600 # Node ID 352cd61e26820f9646c4b9a4ccce4f0d292a87d1 # Parent 1f6c6c678f96e1ea8fdb7aebb8c73ee2708d6c03 modulemanager: Allow loading a module onto "*" (part-fixes #228) diff -r 1f6c6c678f96 -r 352cd61e2682 core/modulemanager.lua --- a/core/modulemanager.lua Sat Apr 21 16:27:42 2012 +0100 +++ b/core/modulemanager.lua Sat Apr 21 20:00:30 2012 +0100 @@ -117,13 +117,15 @@ local function do_load_module(host, module_name) if not (host and module_name) then return nil, "insufficient-parameters"; - elseif not hosts[host] then + elseif not hosts[host] and host ~= "*"then return nil, "unknown-host"; end if not modulemap[host] then modulemap[host] = {}; - hosts[host].modules = modulemap[host]; + if host ~= "*" then + hosts[host].modules = modulemap[host]; + end end if modulemap[host][module_name] then