aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/mod_roster.lua
diff options
context:
space:
mode:
authorWaqas Hussain <waqas20@gmail.com>2009-05-08 01:04:51 +0500
committerWaqas Hussain <waqas20@gmail.com>2009-05-08 01:04:51 +0500
commit6221ed58afee8e9a7c212e1f545b08186d526f70 (patch)
treeab9b13e1919e06f28c8e146bf85f15f561504c60 /plugins/mod_roster.lua
parentea1de379adc79c9c91df0b674f0e50962e8626d2 (diff)
downloadprosody-6221ed58afee8e9a7c212e1f545b08186d526f70.tar.gz
prosody-6221ed58afee8e9a7c212e1f545b08186d526f70.zip
mod_roster: Advertize roster versioning support
Diffstat (limited to 'plugins/mod_roster.lua')
-rw-r--r--plugins/mod_roster.lua8
1 files changed, 8 insertions, 0 deletions
diff --git a/plugins/mod_roster.lua b/plugins/mod_roster.lua
index e30bc1f9..554ef2e5 100644
--- a/plugins/mod_roster.lua
+++ b/plugins/mod_roster.lua
@@ -23,6 +23,14 @@ local core_route_stanza = core_route_stanza;
module:add_feature("jabber:iq:roster");
+local rosterver_stream_feature = st.stanza("ver", {xmlns="urn:xmpp:features:rosterver"}):tag("optional"):up();
+module:add_event_hook("stream-features",
+ function (session, features)
+ if session.username then
+ features:add_child(rosterver_stream_feature);
+ end
+ end);
+
module:add_iq_handler("c2s", "jabber:iq:roster",
function (session, stanza)
if stanza.tags[1].name == "query" then