I am writing a fallback email plugin that sends an email to the destination user if an email address is specified for them. I know it doesn’t really make sense, but that’s what the users at my company want. Currently I am doing this:
to_username = to_jid.getNode();
to_email_addr = to_user_obj.getEmail();
However, this will not work in a federated environment witn non-local JIDs. Is there an api call to turn a JID into a vCard?