Software /
code /
prosody-modules
Diff
mod_smacks/mod_smacks.lua @ 3110:06e07b483805
mod_smacks: Convert max number into a string before inserting it into a stanza.
author | Emmanuel Gil Peyrot <linkmauve@linkmauve.fr> |
---|---|
date | Fri, 08 Jun 2018 17:56:54 +0200 |
parent | 3107:f703cc6e72df |
child | 3150:14b6ad2b773f |
line wrap: on
line diff
--- a/mod_smacks/mod_smacks.lua Fri Jun 08 17:39:43 2018 +0200 +++ b/mod_smacks/mod_smacks.lua Fri Jun 08 17:56:54 2018 +0200 @@ -279,7 +279,7 @@ session_registry.set(session.username, resume_token, session); session.resumption_token = resume_token; end - (session.sends2s or session.send)(st.stanza("enabled", { xmlns = xmlns_sm, id = resume_token, resume = resume, max = resume_timeout })); + (session.sends2s or session.send)(st.stanza("enabled", { xmlns = xmlns_sm, id = resume_token, resume = resume, max = tostring(resume_timeout) })); return true; end module:hook_stanza(xmlns_sm2, "enable", function (session, stanza) return handle_enable(session, stanza, xmlns_sm2); end, 100);