+ ContactInfo contact = account.getContactStore().getContact(source);
+ if (contact != null) {
+ contact.profileKey = Base64.encodeBytes(message.getProfileKey().get());
+ account.getContactStore().updateContact(contact);
+ }
+ } else {
+ ContactInfo contact = account.getContactStore().getContact(source);
+ if (contact == null) {
+ contact = new ContactInfo(source);
+ }
+ contact.profileKey = Base64.encodeBytes(message.getProfileKey().get());
+ account.getContactStore().updateContact(contact);