diff options
Diffstat (limited to 'plugins/mod_pubsub/mod_pubsub.lua')
-rw-r--r-- | plugins/mod_pubsub/mod_pubsub.lua | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/plugins/mod_pubsub/mod_pubsub.lua b/plugins/mod_pubsub/mod_pubsub.lua index 2b07740a..d3d5f59f 100644 --- a/plugins/mod_pubsub/mod_pubsub.lua +++ b/plugins/mod_pubsub/mod_pubsub.lua @@ -59,6 +59,10 @@ function simple_broadcast(kind, node, jids, item, actor) end end +function is_item_stanza(item) + return st.is_stanza(item) and item.attr.xmlns == xmlns_pubsub and item.name == "item"; +end + module:hook("iq/host/"..xmlns_pubsub..":pubsub", handle_pubsub_iq); module:hook("iq/host/"..xmlns_pubsub_owner..":pubsub", handle_pubsub_iq); @@ -207,6 +211,7 @@ function module.load() nodestore = node_store; itemstore = create_simple_itemstore; broadcaster = simple_broadcast; + itemcheck = is_item_stanza; get_affiliation = get_affiliation; normalize_jid = jid_bare; |