Mercurial > prosody-modules
diff mod_csi_battery_saver/mod_csi_battery_saver.lua @ 2757:595d9d68fd11
mod_csi_battery_saver: Fix #921
See also https://mail.jabber.org/pipermail/standards/2017-May/032773.html
author | tmolitor <thilo@eightysoft.de> |
---|---|
date | Sun, 27 Aug 2017 21:35:08 +0200 |
parents | d1aa5fc005f7 |
children | dfac28504e86 |
line wrap: on
line diff
--- a/mod_csi_battery_saver/mod_csi_battery_saver.lua Sun Aug 27 21:34:48 2017 +0200 +++ b/mod_csi_battery_saver/mod_csi_battery_saver.lua Sun Aug 27 21:35:08 2017 +0200 @@ -93,7 +93,8 @@ end local function add_stamp(stanza, session) - stanza = stanza:tag("delay", { xmlns = xmlns_delay, from = session.host, stamp = datetime.datetime()}); + local bare_jid = jid.bare(session.full_jid or session.host); + stanza = stanza:tag("delay", { xmlns = xmlns_delay, from = bare_jid, stamp = datetime.datetime()}); return stanza; end