diff options
author | Waqas Hussain <waqas20@gmail.com> | 2009-06-23 02:15:04 +0500 |
---|---|---|
committer | Waqas Hussain <waqas20@gmail.com> | 2009-06-23 02:15:04 +0500 |
commit | 3f141a44c2b4564e5d88748f76f53f5fec6c1a33 (patch) | |
tree | 73ed9fe47387e4c1d163de8382ec04f46c1a5ced /core/modulemanager.lua | |
parent | dc5b5334b89b26487ab2ac3982bcb55b0c208651 (diff) | |
download | prosody-3f141a44c2b4564e5d88748f76f53f5fec6c1a33.tar.gz prosody-3f141a44c2b4564e5d88748f76f53f5fec6c1a33.zip |
modulemanager: Enabled access to the module API from plugin libraries
Diffstat (limited to 'core/modulemanager.lua')
-rw-r--r-- | core/modulemanager.lua | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/core/modulemanager.lua b/core/modulemanager.lua index 4f24c0a1..f160521f 100644 --- a/core/modulemanager.lua +++ b/core/modulemanager.lua @@ -406,6 +406,7 @@ function api:require(lib) f, n = pluginloader.load_code(lib, lib..".lib.lua"); end if not f then error("Failed to load plugin library '"..lib.."', error: "..n); end -- FIXME better error message + setfenv(f, setmetatable({ module = self }, { __index = _G })); return f(); end |