diff options
author | Emmanuel Gil Peyrot <linkmauve@linkmauve.fr> | 2018-08-24 20:35:33 +0200 |
---|---|---|
committer | Emmanuel Gil Peyrot <linkmauve@linkmauve.fr> | 2018-08-24 20:35:33 +0200 |
commit | cc4ca8f8460a42be7c7cd6d0aaa9f30e5069d42c (patch) | |
tree | d70d0184f236db203e1f39e08454fd5816c142e7 /plugins/mod_version.lua | |
parent | 59b593c0762a74b4317bffdcc63c08d39b8944f6 (diff) | |
download | prosody-cc4ca8f8460a42be7c7cd6d0aaa9f30e5069d42c.tar.gz prosody-cc4ca8f8460a42be7c7cd6d0aaa9f30e5069d42c.zip |
mod_version: Simplify iq handling by hooking on iq-get/ instead of iq/.
Diffstat (limited to 'plugins/mod_version.lua')
-rw-r--r-- | plugins/mod_version.lua | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/plugins/mod_version.lua b/plugins/mod_version.lua index 7f045415..e0d1def7 100644 --- a/plugins/mod_version.lua +++ b/plugins/mod_version.lua @@ -39,9 +39,9 @@ if not module:get_option_boolean("hide_os_type") then end end -module:hook("iq/host/jabber:iq:version:query", function(event) +module:hook("iq-get/host/jabber:iq:version:query", function(event) local stanza = event.stanza; - if stanza.attr.type == "get" and stanza.attr.to == module.host then + if stanza.attr.to == module.host then event.origin.send(st.reply(stanza):add_child(query)); return true; end |