Fixed a crash when VCard support has been disabled

This commit is contained in:
Sylvain Berfini 2019-11-13 09:55:53 +01:00
parent 1b344c3013
commit 4860538466

View file

@ -352,10 +352,11 @@ public class LinphoneContact extends AndroidContact
if (mFriend.getVcard() != null) { if (mFriend.getVcard() != null) {
mFriend.getVcard().setFamilyName(mLastName); mFriend.getVcard().setFamilyName(mLastName);
mFriend.getVcard().setGivenName(mFirstName); mFriend.getVcard().setGivenName(mFirstName);
}
if (mOrganization != null) { if (mOrganization != null) {
mFriend.getVcard().setOrganization(mOrganization); mFriend.getVcard().setOrganization(mOrganization);
} }
}
if (!created) { if (!created) {
for (Address address : mFriend.getAddresses()) { for (Address address : mFriend.getAddresses()) {