From 70fd14ff450a498fd2d43fdce063adc2a5df1579 Mon Sep 17 00:00:00 2001 From: daurnimator Date: Sun, 4 Mar 2018 22:57:26 +1100 Subject: src/lauxlib.js: lua_tojsstring won't throw since b257a24 --- src/lauxlib.js | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'src') diff --git a/src/lauxlib.js b/src/lauxlib.js index 3dfc072..5abbaaa 100644 --- a/src/lauxlib.js +++ b/src/lauxlib.js @@ -227,11 +227,7 @@ const luaL_traceback = function(L, L1, msg, level) { }; const panic = function(L) { - let msg = "PANIC: unprotected error in call to Lua API"; - try { - msg += " (" + lua_tojsstring(L, -1) + ")"; - } catch (e) { - } + let msg = "PANIC: unprotected error in call to Lua API (" + lua_tojsstring(L, -1) + ")"; throw new Error(msg); }; -- cgit v1.2.3-54-g00ecf