From 2e5b595a2e04fe72555a565af4aae43560946473 Mon Sep 17 00:00:00 2001 From: Benoit Giannangeli Date: Wed, 29 Mar 2017 11:57:43 +0200 Subject: Never use js strings internally --- src/lcorolib.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/lcorolib.js') diff --git a/src/lcorolib.js b/src/lcorolib.js index b2d0de8..58d061c 100644 --- a/src/lcorolib.js +++ b/src/lcorolib.js @@ -8,12 +8,13 @@ const lauxlib = require('./lauxlib.js'); const lstate = require('./lstate.js'); const ldo = require('./ldo.js'); const ldebug = require('./ldebug.js'); +const lobject = require('./lobject.js'); const CT = lua.constant_types; const TS = lua.thread_status; const getco = function(L) { let co = lapi.lua_tothread(L, 1); - lauxlib.luaL_argcheck(L, co, 1, "thread expected"); + lauxlib.luaL_argcheck(L, co, 1, lua.to_luastring("thread expected")); return co; }; @@ -146,4 +147,4 @@ const luaopen_coroutine = function(L) { return 1; }; -module.exports.luaopen_coroutine = luaopen_coroutine; \ No newline at end of file +module.exports.luaopen_coroutine = luaopen_coroutine; -- cgit v1.2.3-54-g00ecf