core.module{manager,api}: Fix for 010b141e91ed (Thanks v1ct0r)

This commit is contained in:
Kim Alvefur 2014-09-23 00:23:33 +02:00
parent ea8046b81b
commit b58d3248b7
2 changed files with 4 additions and 2 deletions

View file

@ -370,7 +370,9 @@ function api:open_store(name, type)
return require"core.storagemanager".open(self.host, name or self.name, type);
end
return function (mm)
function api.init(mm)
modulemanager = mm;
return api;
end
return api;

View file

@ -37,7 +37,7 @@ local _G = _G;
module "modulemanager"
local api = _G.require "core.moduleapi"(_M); -- Module API container
local api = _G.require "core.moduleapi".init(_M); -- Module API container
-- [host] = { [module] = module_env }
local modulemap = { ["*"] = {} };