implement slightly more of conversation client to get delete messages test passing

This commit is contained in:
ameba23
2021-03-17 08:41:39 +01:00
parent 6d0aebd7ec
commit 0658e90c65

View File

@@ -314,7 +314,15 @@ class SocialBackupManagerImpl extends ConversationClientImpl
@Override
public Set<MessageId> getMessageIds(Transaction txn, ContactId contactId)
throws DbException {
return null;
Contact contact = db.getContact(txn, contactId);
GroupId contactGroupId = getContactGroup(contact).getId();
try {
Map<MessageId, BdfDictionary> messages = clientHelper
.getMessageMetadataAsDictionary(txn, contactGroupId);
return messages.keySet();
} catch (FormatException e) {
throw new DbException(e);
}
}
@Override
@@ -326,7 +334,8 @@ class SocialBackupManagerImpl extends ConversationClientImpl
@Override
public DeletionResult deleteMessages(Transaction txn, ContactId c,
Set<MessageId> messageIds) throws DbException {
return null;
DeletionResult result = new DeletionResult();
return result;
}
private void setContactId(Transaction txn, GroupId g, ContactId c)