Software /
code /
prosody
Comparison
plugins/mod_proxy65.lua @ 3694:a7d88f58abbb
mod_proxy65: Add service discovery identity and feature, to help out mod_disco when loaded on a normal host.
author | Waqas Hussain <waqas20@gmail.com> |
---|---|
date | Fri, 03 Dec 2010 00:29:44 +0500 |
parent | 3693:519f5eadf4b9 |
child | 4374:c38f20f172b3 |
comparison
equal
deleted
inserted
replaced
3693:519f5eadf4b9 | 3694:a7d88f58abbb |
---|---|
115 -- Clean up any session-related stuff here | 115 -- Clean up any session-related stuff here |
116 sessions[conn] = nil; | 116 sessions[conn] = nil; |
117 end | 117 end |
118 end | 118 end |
119 | 119 |
120 module:add_identity("proxy", "bytestreams", name); | |
121 module:add_feature("http://jabber.org/protocol/bytestreams"); | |
122 | |
120 module:hook("iq-get/host/http://jabber.org/protocol/disco#info:query", function(event) | 123 module:hook("iq-get/host/http://jabber.org/protocol/disco#info:query", function(event) |
121 local origin, stanza = event.origin, event.stanza; | 124 local origin, stanza = event.origin, event.stanza; |
122 local reply = replies_cache.disco_info; | 125 local reply = replies_cache.disco_info; |
123 if reply == nil then | 126 if reply == nil then |
124 reply = st.iq({type='result', from=host}):query("http://jabber.org/protocol/disco#info") | 127 reply = st.iq({type='result', from=host}):query("http://jabber.org/protocol/disco#info") |