summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/lstrlib.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lstrlib.js b/src/lstrlib.js
index 37a3287..f5b9f34 100644
--- a/src/lstrlib.js
+++ b/src/lstrlib.js
@@ -631,7 +631,7 @@ const str_pack = function(L) {
};
const str_reverse = function(L) {
- lua.lua_pushstring(L, lauxlib.luaL_checkstring(L, 1).reverse());
+ lua.lua_pushstring(L, lauxlib.luaL_checkstring(L, 1).slice(0).reverse());
return 1;
};