mirror of
https://github.com/AsamK/signal-cli
synced 2025-08-29 10:30:38 +00:00
Update libsignal-service-java
This commit is contained in:
parent
d2251ccd14
commit
842f13b2fc
3 changed files with 41 additions and 25 deletions
|
@ -345,29 +345,41 @@ public class SendHelper {
|
|||
},
|
||||
() -> false,
|
||||
urgent);
|
||||
final SenderKeySenderHandler senderKeySender = (distId, recipients, unidentifiedAccess, isRecipientUpdate) -> {
|
||||
final var res = messageSender.sendGroupDataMessage(distId,
|
||||
recipients,
|
||||
unidentifiedAccess,
|
||||
isRecipientUpdate,
|
||||
contentHint,
|
||||
message,
|
||||
SignalServiceMessageSender.SenderKeyGroupEvents.EMPTY,
|
||||
urgent,
|
||||
false);
|
||||
synchronized (entryId) {
|
||||
if (entryId.get() == -1) {
|
||||
final var newId = messageSendLogStore.insertIfPossible(message.getTimestamp(),
|
||||
res,
|
||||
contentHint,
|
||||
urgent);
|
||||
entryId.set(newId);
|
||||
} else {
|
||||
messageSendLogStore.addRecipientToExistingEntryIfPossible(entryId.get(), res);
|
||||
}
|
||||
}
|
||||
return res;
|
||||
};
|
||||
final SenderKeySenderHandler senderKeySender = (distId, recipients, unidentifiedAccess, isRecipientUpdate) -> messageSender.sendGroupDataMessage(
|
||||
distId,
|
||||
recipients,
|
||||
unidentifiedAccess,
|
||||
isRecipientUpdate,
|
||||
contentHint,
|
||||
message,
|
||||
SignalServiceMessageSender.SenderKeyGroupEvents.EMPTY,
|
||||
urgent,
|
||||
false,
|
||||
sendResult -> {
|
||||
logger.trace("Partial message send results: {}", sendResult.size());
|
||||
synchronized (entryId) {
|
||||
if (entryId.get() == -1) {
|
||||
final var newId = messageSendLogStore.insertIfPossible(message.getTimestamp(),
|
||||
sendResult,
|
||||
contentHint,
|
||||
urgent);
|
||||
entryId.set(newId);
|
||||
} else {
|
||||
messageSendLogStore.addRecipientToExistingEntryIfPossible(entryId.get(), sendResult);
|
||||
}
|
||||
}
|
||||
synchronized (entryId) {
|
||||
if (entryId.get() == -1) {
|
||||
final var newId = messageSendLogStore.insertIfPossible(message.getTimestamp(),
|
||||
sendResult,
|
||||
contentHint,
|
||||
urgent);
|
||||
entryId.set(newId);
|
||||
} else {
|
||||
messageSendLogStore.addRecipientToExistingEntryIfPossible(entryId.get(), sendResult);
|
||||
}
|
||||
}
|
||||
});
|
||||
final var results = sendGroupMessageInternal(legacySender, senderKeySender, recipientIds, distributionId);
|
||||
|
||||
for (var r : results) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue