Comparison

plugins/mod_mam/mod_mam.lua @ 10076:ee85cea08127

mod_mam: Log query failure reason The storage engine will usually make a lot of noise for serious errors, but not always.
author Kim Alvefur <zash@zash.se>
date Thu, 11 Jul 2019 23:27:01 +0200
parent 10075:5f58a81c7dcc
child 10077:c0702a1534cb
comparison
equal deleted inserted replaced
10075:5f58a81c7dcc 10076:ee85cea08127
141 reverse = reverse; 141 reverse = reverse;
142 total = use_total or qmax == 0; 142 total = use_total or qmax == 0;
143 }); 143 });
144 144
145 if not data then 145 if not data then
146 module:log("debug", "Archive query id=%s failed: %s", qid or stanza.attr.id, err);
146 if err == "item-not-found" then 147 if err == "item-not-found" then
147 origin.send(st.error_reply(stanza, "modify", "item-not-found")); 148 origin.send(st.error_reply(stanza, "modify", "item-not-found"));
148 else 149 else
149 origin.send(st.error_reply(stanza, "cancel", "internal-server-error")); 150 origin.send(st.error_reply(stanza, "cancel", "internal-server-error"));
150 end 151 end