Mercurial > prosody-modules
diff mod_rest/jsonmap.lib.lua @ 4954:e8a487c42b36
merge upstream
author | Goffi <goffi@goffi.org> |
---|---|
date | Sat, 28 May 2022 16:43:04 +0200 |
parents | b171ddf1bc3e |
children | 048e339706ba |
line wrap: on
line diff
--- a/mod_rest/jsonmap.lib.lua Sat May 28 16:42:13 2022 +0200 +++ b/mod_rest/jsonmap.lib.lua Sat May 28 16:43:04 2022 +0200 @@ -506,6 +506,13 @@ local archive = t.archive; if archive["with"] or archive["start"] or archive["end"] or archive["before-id"] or archive["after-id"] or archive["ids"] then + if type(archive["ids"]) == "string" then + local ids = {}; + for id in archive["ids"]:gmatch("[^,]+") do + table.insert(ids, id); + end + archive["ids"] = ids; + end archive.form = { type = "submit"; fields = {