# HG changeset patch # User Kim Alvefur # Date 1469531324 -7200 # Node ID a96f2d0f8750b1735d9b1c682b6b9897785c79ad # Parent 48c3d64a3fc1032261ccb46fe5b7f2cadc52ad37 mod_cloud_notify: Add some logging when a client attempts to enable push notifications diff -r 48c3d64a3fc1 -r a96f2d0f8750 mod_cloud_notify/mod_cloud_notify.lua --- a/mod_cloud_notify/mod_cloud_notify.lua Tue Jul 26 12:37:04 2016 +0200 +++ b/mod_cloud_notify/mod_cloud_notify.lua Tue Jul 26 13:08:44 2016 +0200 @@ -26,6 +26,7 @@ -- http://xmpp.org/extensions/xep-0357.html#enabling module:hook("iq-set/self/"..xmlns_push..":enable", function (event) local origin, stanza = event.origin, event.stanza; + origin.log("debug", "Attempting to enable push notifications"); -- MUST contain a 'jid' attribute of the XMPP Push Service being enabled local push_jid = stanza.tags[1].attr.jid; -- SHOULD contain a 'node' attribute @@ -53,6 +54,7 @@ if not ok then origin.send(st.error_reply(stanza, "wait", "internal-server-error")); else + origin.log("info", "Push notifications enabled"); origin.send(st.reply(stanza)); end return true;