Changeset

10079:a36c731ed540

mod_mam: Report correct count of results for forward queries #results is only correct for backwards queries, the table is unused for forward queries.
author Kim Alvefur <zash@zash.se>
date Sat, 13 Jul 2019 19:57:43 +0200
parents 10078:44371850c6b0
children 10080:39ca4202ae1e
files plugins/mod_mam/mod_mam.lua
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/plugins/mod_mam/mod_mam.lua	Thu Jul 11 23:29:59 2019 +0200
+++ b/plugins/mod_mam/mod_mam.lua	Sat Jul 13 19:57:43 2019 +0200
@@ -206,7 +206,7 @@
 				first = first, last = last, count = total }));
 
 	-- That's all folks!
-	module:log("debug", "Archive query id=%s completed, %d items returned", qid or stanza.attr.id, #results);
+	module:log("debug", "Archive query id=%s completed, %d items returned", qid or stanza.attr.id, complete and count or count - 1);
 	return true;
 end);