Software /
code /
prosody
Comparison
core/moduleapi.lua @ 12590:5eaf77114fdb
compat: Use table.pack (there since Lua 5.2) over our util.table
Added in d278a770eddc avoid having to deal with its absence in Lua 5.1.
No longer needed when Lua 5.1 support is dropped.
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Mon, 11 Jul 2022 19:15:24 +0200 |
parent | 12589:39ae08180c81 |
child | 12642:9061f9621330 |
comparison
equal
deleted
inserted
replaced
12589:39ae08180c81 | 12590:5eaf77114fdb |
---|---|
24 local t_insert, t_remove, t_concat = table.insert, table.remove, table.concat; | 24 local t_insert, t_remove, t_concat = table.insert, table.remove, table.concat; |
25 local error, setmetatable, type = error, setmetatable, type; | 25 local error, setmetatable, type = error, setmetatable, type; |
26 local ipairs, pairs, select = ipairs, pairs, select; | 26 local ipairs, pairs, select = ipairs, pairs, select; |
27 local tonumber, tostring = tonumber, tostring; | 27 local tonumber, tostring = tonumber, tostring; |
28 local require = require; | 28 local require = require; |
29 local pack = table.pack or require "util.table".pack; -- table.pack is only in 5.2 | 29 local pack = table.pack; |
30 local unpack = table.unpack; | 30 local unpack = table.unpack; |
31 | 31 |
32 local prosody = prosody; | 32 local prosody = prosody; |
33 local hosts = prosody.hosts; | 33 local hosts = prosody.hosts; |
34 | 34 |