Software /
code /
prosody-modules
Diff
mod_cloud_notify/mod_cloud_notify.lua @ 4429:157fa4e535b0
mod_cloud_notify: Fix nesting of push form (thanks ivucica/Andrzej)
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Fri, 05 Feb 2021 12:36:48 +0000 |
parent | 4412:e5493a10c4d1 |
child | 4464:ea820de69265 |
line wrap: on
line diff
--- a/mod_cloud_notify/mod_cloud_notify.lua Thu Feb 04 20:49:02 2021 +0100 +++ b/mod_cloud_notify/mod_cloud_notify.lua Fri Feb 05 12:36:48 2021 +0000 @@ -337,12 +337,13 @@ form_data["last-message-body"] = tostring(dummy_body); end + push_notification_payload:add_child(push_form:form(form_data)); + local push_publish = st.iq({ to = push_info.jid, from = module.host, type = "set", id = stanza_id }) :tag("pubsub", { xmlns = "http://jabber.org/protocol/pubsub" }) :tag("publish", { node = push_info.node }) :tag("item") :add_child(push_notification_payload) - :add_child(push_form:form(form_data)) :up() :up();