util.prosodyctl: Remove Lua 5.1 os.execute() return value compat

This commit is contained in:
Kim Alvefur 2022-10-20 17:37:07 +02:00
parent 640b8d49a3
commit e673312b7f

View file

@ -224,8 +224,7 @@ local function call_luarocks(operation, mod, server)
local ok, _, code = os.execute(render_cli("luarocks --lua-version={luav} {op} --tree={dir} {server&--server={server}} {mod?}", {
dir = dir; op = operation; mod = mod; server = server; luav = _VERSION:match("5%.%d");
}));
if type(ok) == "number" then code = ok; end
return code;
return ok and code;
end
return {