diff options
author | daurnimator <quae@daurnimator.com> | 2017-05-30 17:13:43 +1000 |
---|---|---|
committer | daurnimator <quae@daurnimator.com> | 2017-05-30 17:13:43 +1000 |
commit | d0018d43f46d3c32508094a3a3c2e73cc6acf3ff (patch) | |
tree | 5b75feeb2251dee40f96b209aa7878e9848f41e8 /src | |
parent | 01992a64dc3888cc5d58771b3592c5331a3a270e (diff) | |
download | fengari-d0018d43f46d3c32508094a3a3c2e73cc6acf3ff.tar.gz fengari-d0018d43f46d3c32508094a3a3c2e73cc6acf3ff.tar.bz2 fengari-d0018d43f46d3c32508094a3a3c2e73cc6acf3ff.zip |
src/lbaselib.js: Fix misleading error message from collectgarbage()
Diffstat (limited to 'src')
-rw-r--r-- | src/lbaselib.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lbaselib.js b/src/lbaselib.js index 04a5e8d..b2a9951 100644 --- a/src/lbaselib.js +++ b/src/lbaselib.js @@ -92,7 +92,7 @@ const opts = ["stop", "restart", "collect", "isrunning"].map((e) => lua.to_luastring(e)); const luaB_collectgarbage = function(L) { lauxlib.luaL_checkoption(L, 1, lua.to_luastring("collect"), opts); - lauxlib.luaL_checkinteger(L, 2); + lauxlib.luaL_optinteger(L, 2, 0); lauxlib.luaL_error(L, lua.to_luastring("lua_gc not implemented")); }; |