Software / code / prosody
Changeset
12574:18d33668c5fa
mod_storage_sql: Remove Lua 5.1 compatibility hack
Part of #1600
| author | Kim Alvefur <zash@zash.se> |
|---|---|
| date | Sat, 02 Jul 2022 17:30:06 +0200 |
| parents | 12573:0f4feaf9ca64 |
| children | 12575:1f6f05a98fcd |
| files | plugins/mod_storage_sql.lua |
| diffstat | 1 files changed, 1 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/plugins/mod_storage_sql.lua Sat Jul 02 17:31:14 2022 +0200 +++ b/plugins/mod_storage_sql.lua Sat Jul 02 17:30:06 2022 +0200 @@ -382,8 +382,7 @@ -- Set of ids if query.ids then local nids, nargs = #query.ids, #args; - -- COMPAT Lua 5.1: No separator argument to string.rep - where[#where + 1] = "\"key\" IN (" .. string.rep("?,", nids):sub(1,-2) .. ")"; + where[#where + 1] = "\"key\" IN (" .. string.rep("?", nids, ",") .. ")"; for i, id in ipairs(query.ids) do args[nargs+i] = id; end