mirror of
https://code.briarproject.org/briar/briar.git
synced 2026-02-17 05:09:53 +01:00
add isLocal boolean to shard message headers
This commit is contained in:
@@ -292,16 +292,17 @@ class SocialBackupManagerImpl extends ConversationClientImpl
|
|||||||
.getMessageMetadataAsDictionary(txn, contactGroupId);
|
.getMessageMetadataAsDictionary(txn, contactGroupId);
|
||||||
List<ConversationMessageHeader> headers =
|
List<ConversationMessageHeader> headers =
|
||||||
new ArrayList<>();
|
new ArrayList<>();
|
||||||
List<AttachmentHeader> attachmentHeaders = new ArrayList<>();
|
|
||||||
for (Entry<MessageId, BdfDictionary> messageEntry : messages
|
for (Entry<MessageId, BdfDictionary> messageEntry : messages
|
||||||
.entrySet()) {
|
.entrySet()) {
|
||||||
BdfDictionary message = messageEntry.getValue();
|
BdfDictionary message = messageEntry.getValue();
|
||||||
if (message.getLong(MSG_KEY_MESSAGE_TYPE).intValue() ==
|
if (message.getLong(MSG_KEY_MESSAGE_TYPE).intValue() ==
|
||||||
SHARD.getValue()) {
|
SHARD.getValue()) {
|
||||||
long timestamp = message.getLong(MSG_KEY_TIMESTAMP);
|
long timestamp = message.getLong(MSG_KEY_TIMESTAMP);
|
||||||
|
boolean isLocal = message.getBoolean(MSG_KEY_LOCAL);
|
||||||
|
List<AttachmentHeader> attachmentHeaders = new ArrayList<>();
|
||||||
ShardMessageHeader shardHeader = new ShardMessageHeader(
|
ShardMessageHeader shardHeader = new ShardMessageHeader(
|
||||||
messageEntry.getKey(), contactGroupId, timestamp,
|
messageEntry.getKey(), contactGroupId, timestamp,
|
||||||
false, false, false, false, attachmentHeaders);
|
isLocal, false, true, false, attachmentHeaders);
|
||||||
headers.add(shardHeader);
|
headers.add(shardHeader);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user