diff options
author | daurnimator <quae@daurnimator.com> | 2018-02-04 15:58:05 -0800 |
---|---|---|
committer | daurnimator <quae@daurnimator.com> | 2018-02-04 15:58:05 -0800 |
commit | b42f1c3e18bab816203cc34a9af4d1c11e55199b (patch) | |
tree | d11f71beb6cb500a2e78b1f37195173e8552903b /src/lauxlib.js | |
parent | 1f486bd421bba7f93e6119ed9fde711c2799f96d (diff) | |
download | fengari-b42f1c3e18bab816203cc34a9af4d1c11e55199b.tar.gz fengari-b42f1c3e18bab816203cc34a9af4d1c11e55199b.tar.bz2 fengari-b42f1c3e18bab816203cc34a9af4d1c11e55199b.zip |
{src/lauxlib.js,tests/test-suite/ltests.js}: Use luastring_eq instead of .join()
Diffstat (limited to 'src/lauxlib.js')
-rw-r--r-- | src/lauxlib.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lauxlib.js b/src/lauxlib.js index 437b6cf..d5b943b 100644 --- a/src/lauxlib.js +++ b/src/lauxlib.js @@ -368,7 +368,7 @@ const luaL_checkudata = function(L, ud, tname) { const luaL_checkoption = function(L, arg, def, lst) { let name = def ? luaL_optstring(L, arg, def) : luaL_checkstring(L, arg); for (let i = 0; lst[i]; i++) - if (lst[i].join('|') === name.join('|')) + if (luastring_eq(lst[i], name)) return i; return luaL_argerror(L, arg, lua_pushfstring(L, to_luastring("invalid option '%s'"), name)); }; |