Add introduced contacts as UNVERIFIED

Closes #580
This commit is contained in:
Torsten Grote
2016-08-10 12:35:33 -03:00
parent 70b311db13
commit e690bcb3cc
22 changed files with 201 additions and 126 deletions

View File

@@ -311,7 +311,7 @@ public class ContactExchangeTaskImpl extends Thread
Transaction txn = db.startTransaction(false);
try {
contactId = contactManager.addContact(txn, remoteAuthor,
localAuthor.getId(), master, timestamp, alice, true);
localAuthor.getId(), master, timestamp, alice, true, true);
transportPropertyManager.addRemoteProperties(txn, contactId,
remoteProperties);
txn.setComplete();

View File

@@ -48,9 +48,9 @@ class ContactManagerImpl implements ContactManager, RemoveIdentityHook {
@Override
public ContactId addContact(Transaction txn, Author remote, AuthorId local,
SecretKey master,long timestamp, boolean alice, boolean active)
throws DbException {
ContactId c = db.addContact(txn, remote, local, active);
SecretKey master,long timestamp, boolean alice, boolean verified,
boolean active) throws DbException {
ContactId c = db.addContact(txn, remote, local, verified, active);
keyManager.addContact(txn, c, master, timestamp, alice);
Contact contact = db.getContact(txn, c);
for (AddContactHook hook : addHooks)
@@ -60,13 +60,13 @@ class ContactManagerImpl implements ContactManager, RemoveIdentityHook {
@Override
public ContactId addContact(Author remote, AuthorId local, SecretKey master,
long timestamp, boolean alice, boolean active)
long timestamp, boolean alice, boolean verified, boolean active)
throws DbException {
ContactId c;
Transaction txn = db.startTransaction(false);
try {
c = addContact(txn, remote, local, master, timestamp, alice,
active);
verified, active);
txn.setComplete();
} finally {
db.endTransaction(txn);