mirror of https://github.com/M66B/FairEmail.git
Always update existing local contacts
This commit is contained in:
parent
cc5db29320
commit
7724e5b46f
|
@ -587,8 +587,13 @@ public class FragmentContacts extends FragmentBase {
|
||||||
EntityContact contact;
|
EntityContact contact;
|
||||||
if (id > 0)
|
if (id > 0)
|
||||||
contact = db.contact().getContact(id);
|
contact = db.contact().getContact(id);
|
||||||
else
|
else {
|
||||||
contact = new EntityContact();
|
contact = db.contact().getContact(account, type, email);
|
||||||
|
if (contact == null)
|
||||||
|
contact = new EntityContact();
|
||||||
|
else
|
||||||
|
id = contact.id;
|
||||||
|
}
|
||||||
|
|
||||||
contact.account = account;
|
contact.account = account;
|
||||||
contact.type = type;
|
contact.type = type;
|
||||||
|
|
Loading…
Reference in New Issue