diff options
author | Kim Alvefur <zash@zash.se> | 2019-08-02 21:57:57 +0200 |
---|---|---|
committer | Kim Alvefur <zash@zash.se> | 2019-08-02 21:57:57 +0200 |
commit | b6ba263f15f7a5eaf6e2df2980d7c9d3b2cc9528 (patch) | |
tree | c786ee91e7b0fa0b7cd6b563d5cb7b8275d76fc6 | |
parent | d572adfb0940f1d0bc6e6438af3f2b83749da998 (diff) | |
download | prosody-b6ba263f15f7a5eaf6e2df2980d7c9d3b2cc9528.tar.gz prosody-b6ba263f15f7a5eaf6e2df2980d7c9d3b2cc9528.zip |
mod_vcard_legacy: Complete roundtrip support for ORG/ORGNAME
vcard-temp -> vcard4 worked previously but not the other way around
-rw-r--r-- | plugins/mod_vcard_legacy.lua | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/plugins/mod_vcard_legacy.lua b/plugins/mod_vcard_legacy.lua index 45988fa8..89ef1a4f 100644 --- a/plugins/mod_vcard_legacy.lua +++ b/plugins/mod_vcard_legacy.lua @@ -110,6 +110,10 @@ module:hook("iq-get/bare/vcard-temp:vCard", function (event) if uri and uri:sub(1, 5) == "xmpp:" then vcard_temp:text_tag("JABBERID", uri:sub(6)) end + elseif tag.name == "org" then + vcard_temp:tag("ORG") + :text_tag("ORGNAME", tag:get_child_text("text")) + :up(); end end end |