-
-
Notifications
You must be signed in to change notification settings - Fork 367
Closed as not planned
Description
It seems like MessageReceivedV2 is sent without attachments, as opposed to MessageReceived which is sent properly.
Please compare these signal bodies:
MessageReceived: [1766395713917,"8fe59ea5-c0d8-4e14-bb2b-3fa5b8f8a4ec","","",["/home/uquark/.local/share/signal-cli/attachments/LN8GvhPhPz3tDLmtvqq0.jpg"]
MessageReceivedV2: [1766395713917,"8fe59ea5-c0d8-4e14-bb2b-3fa5b8f8a4ec","","",{"attachments":{},"expiresInSeconds":{},"isViewOnce":{}}]
In code, I can see construction of the body:
private HashMap<String, Variant<?>> getMessageExtras(MessageEnvelope.Data message) {
var extras = new HashMap<String, Variant<?>>();
if (!message.attachments().isEmpty()) {
var attachments = message.attachments()
.stream()
.filter(a -> a.id().isPresent())
.map(this::getAttachmentMap)
.toList();
extras.put("attachments", new Variant<>(attachments, "aa{sv}"));
}
...attachments here is an array of Attachment records. I am not intimately familiar with DBus type signatures, but it seems like aa{sv} is not correct.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels