comparison plugins/mod_vcard.lua @ 11120:b2331f3dfeea

Merge 0.11->trunk
author Matthew Wild <mwild1@gmail.com>
date Wed, 30 Sep 2020 09:50:33 +0100
parents f1cf8c08a09d
children 74b9e05af71e
comparison
equal deleted inserted replaced
11119:68df52bf08d5 11120:b2331f3dfeea
17 local session, stanza = event.origin, event.stanza; 17 local session, stanza = event.origin, event.stanza;
18 local to = stanza.attr.to; 18 local to = stanza.attr.to;
19 if stanza.attr.type == "get" then 19 if stanza.attr.type == "get" then
20 local vCard; 20 local vCard;
21 if to then 21 if to then
22 local node, host = jid_split(to); 22 local node = jid_split(to);
23 vCard = st.deserialize(vcards:get(node)); -- load vCard for user or server 23 vCard = st.deserialize(vcards:get(node)); -- load vCard for user or server
24 else 24 else
25 vCard = st.deserialize(vcards:get(session.username));-- load user's own vCard 25 vCard = st.deserialize(vcards:get(session.username));-- load user's own vCard
26 end 26 end
27 if vCard then 27 if vCard then