Comparison

mod_mam/mod_mam.lua @ 2019:7198c129657c

mod_mam: Always convert 'total' to a number
author Kim Alvefur <zash@zash.se>
date Tue, 19 Jan 2016 14:33:02 +0100
parent 2018:13f46d9e526f
child 2020:37b30f10fbba
comparison
equal deleted inserted replaced
2018:13f46d9e526f 2019:7198c129657c
140 140
141 if not data then 141 if not data then
142 origin.send(st.error_reply(stanza, "cancel", "internal-server-error", err)); 142 origin.send(st.error_reply(stanza, "cancel", "internal-server-error", err));
143 return true; 143 return true;
144 end 144 end
145 local total = err; 145 local total = tonumber(err);
146 146
147 origin.send(st.reply(stanza)); 147 origin.send(st.reply(stanza));
148 local msg_reply_attr = { to = stanza.attr.from, from = stanza.attr.to }; 148 local msg_reply_attr = { to = stanza.attr.from, from = stanza.attr.to };
149 149
150 local results = {}; 150 local results = {};