Software /
code /
prosody-modules
Comparison
mod_mam_muc/mod_mam_muc.lua @ 2502:f576ac1cad65
mod_mam_muc: Move swapping of reversed variables (like 5fb917b86838 for mod_mam)
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Tue, 14 Feb 2017 09:53:09 +0100 |
parent | 2501:04064f01df0e |
child | 2507:b8a66805459e |
comparison
equal
deleted
inserted
replaced
2501:04064f01df0e | 2502:f576ac1cad65 |
---|---|
257 | 257 |
258 if reverse then | 258 if reverse then |
259 for i = #results, 1, -1 do | 259 for i = #results, 1, -1 do |
260 origin.send(results[i]); | 260 origin.send(results[i]); |
261 end | 261 end |
262 first, last = last, first; | |
262 end | 263 end |
263 | 264 |
264 -- That's all folks! | 265 -- That's all folks! |
265 module:log("debug", "Archive query %s completed", tostring(qid)); | 266 module:log("debug", "Archive query %s completed", tostring(qid)); |
266 | 267 |
267 if reverse then first, last = last, first; end | |
268 origin.send(st.message(msg_reply_attr) | 268 origin.send(st.message(msg_reply_attr) |
269 :tag("fin", { xmlns = xmlns_mam, queryid = qid, complete = complete }) | 269 :tag("fin", { xmlns = xmlns_mam, queryid = qid, complete = complete }) |
270 :add_child(rsm.generate { | 270 :add_child(rsm.generate { |
271 first = first, last = last, count = total })); | 271 first = first, last = last, count = total })); |
272 return true; | 272 return true; |