mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-02-21 10:17:56 +00:00
Enable kotlin for libsignal-service project and convert SignalServiceDataMessage.
This commit is contained in:
@@ -68,7 +68,7 @@ public class PointerAttachment extends Attachment {
|
||||
return results;
|
||||
}
|
||||
|
||||
public static List<Attachment> forPointers(List<SignalServiceDataMessage.Quote.QuotedAttachment> pointers) {
|
||||
public static List<Attachment> forPointers(@Nullable List<SignalServiceDataMessage.Quote.QuotedAttachment> pointers) {
|
||||
List<Attachment> results = new LinkedList<>();
|
||||
|
||||
if (pointers != null) {
|
||||
|
||||
@@ -198,6 +198,7 @@ import java.util.concurrent.TimeUnit;
|
||||
* Takes data about a decrypted message, transforms it into user-presentable data, and writes that
|
||||
* data to our data stores.
|
||||
*/
|
||||
@SuppressWarnings({ "OptionalGetWithoutIsPresent", "OptionalIsPresent" })
|
||||
public final class MessageContentProcessor {
|
||||
|
||||
private static final String TAG = Log.tag(MessageContentProcessor.class);
|
||||
@@ -616,7 +617,7 @@ public final class MessageContentProcessor {
|
||||
database.markAsMissedCall(smsMessageId.get(), message.getType() == OfferMessage.Type.VIDEO_CALL);
|
||||
} else {
|
||||
RemotePeer remotePeer = new RemotePeer(senderRecipient.getId(), new CallId(message.getId()));
|
||||
byte[] remoteIdentityKey = ApplicationDependencies.getProtocolStore().aci().identities().getIdentityRecord(senderRecipient.getId()).map(record -> record.getIdentityKey().serialize()).orElse(null);
|
||||
byte[] remoteIdentityKey = ApplicationDependencies.getProtocolStore().aci().identities().getIdentityRecord(senderRecipient.getId()).map(record -> record.getIdentityKey().serialize()).get();
|
||||
|
||||
ApplicationDependencies.getSignalCallManager()
|
||||
.receivedOffer(new WebRtcData.CallMetadata(remotePeer, content.getSenderDevice()),
|
||||
@@ -634,7 +635,7 @@ public final class MessageContentProcessor {
|
||||
{
|
||||
log(String.valueOf(content), "handleCallAnswerMessage...");
|
||||
RemotePeer remotePeer = new RemotePeer(senderRecipient.getId(), new CallId(message.getId()));
|
||||
byte[] remoteIdentityKey = ApplicationDependencies.getProtocolStore().aci().identities().getIdentityRecord(senderRecipient.getId()).map(record -> record.getIdentityKey().serialize()).orElse(null);
|
||||
byte[] remoteIdentityKey = ApplicationDependencies.getProtocolStore().aci().identities().getIdentityRecord(senderRecipient.getId()).map(record -> record.getIdentityKey().serialize()).get();
|
||||
|
||||
ApplicationDependencies.getSignalCallManager()
|
||||
.receivedAnswer(new WebRtcData.CallMetadata(remotePeer, content.getSenderDevice()),
|
||||
|
||||
Reference in New Issue
Block a user