fix: remove package module load entirely, unnecessary

This commit is contained in:
program-- 2022-11-09 14:09:36 -08:00
parent 9a531a8945
commit fa74ffa10f
1 changed files with 0 additions and 4 deletions

View File

@ -105,7 +105,6 @@ func (pl *lStatePool) New() *lua.LState {
moduleName string
moduleFn lua.LGFunction
}{
{lua.LoadLibName, lua.OpenPackage},
{lua.BaseLibName, openBaseSubset},
{lua.TabLibName, lua.OpenTable},
{lua.MathLibName, lua.OpenMath},
@ -124,9 +123,6 @@ func (pl *lStatePool) New() *lua.LState {
}
}
// Set package module to Nil so loaders can't be accessed
L.SetGlobal("package", lua.LNil)
getArgs := func(ls *lua.LState) (evalCmd string, args []string) {
evalCmd = ls.GetGlobal("EVAL_CMD").String()