summaryrefslogtreecommitdiff
path: root/src/linit.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/linit.js')
-rw-r--r--src/linit.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/linit.js b/src/linit.js
index 2747fc2..fc2a54d 100644
--- a/src/linit.js
+++ b/src/linit.js
@@ -8,15 +8,15 @@ const lauxlib = require('./lauxlib.js');
const lbaselib = require('./lbaselib.js');
const loadedlibs = {
- "_G" = luaopen_base
+ "_G": lbaselib.luaopen_base
};
const luaL_openlibs = function(L) {
/* "require" functions from 'loadedlibs' and set results to global table */
- for (lib in loadedlibs) {
+ for (let lib in loadedlibs) {
lauxlib.luaL_requiref(L, lib, loadedlibs[lib], 1);
lapi.lua_pop(L, 1); /* remove lib */
}
-}
+};
module.exports.luaL_openlibs = luaL_openlibs; \ No newline at end of file