# HG changeset patch # User Kim Alvefur # Date 1536418169 -7200 # Node ID e977b64ebd81bfb1aceb3a6da0449dedd0146a16 # Parent 778d2dbfc784cd0076fc994784525a1f6a3f564d mod_vcard4: Advertise feature on account instead of host diff -r 778d2dbfc784 -r e977b64ebd81 plugins/mod_vcard4.lua --- a/plugins/mod_vcard4.lua Sat Sep 08 11:52:44 2018 +0200 +++ b/plugins/mod_vcard4.lua Sat Sep 08 16:49:29 2018 +0200 @@ -3,7 +3,9 @@ local mod_pep = module:depends("pep"); -module:add_feature("urn:ietf:params:xml:ns:vcard-4.0"); +module:hook("account-disco-info", function (event) + event.reply:tag("feature", { var = "urn:ietf:params:xml:ns:vcard-4.0" }):up(); +end); module:hook("iq-get/bare/urn:ietf:params:xml:ns:vcard-4.0:vcard", function (event) local origin, stanza = event.origin, event.stanza;