mirror of
https://github.com/aljazceru/signal-cli.git
synced 2025-12-26 02:24:21 +01:00
Output attachment id as json string to prevent rounding due to conversion to double
Fixes #226
This commit is contained in:
@@ -7,7 +7,7 @@ class JsonAttachment {
|
||||
|
||||
String contentType;
|
||||
String filename;
|
||||
long id;
|
||||
String id;
|
||||
int size;
|
||||
|
||||
JsonAttachment(SignalServiceAttachment attachment) {
|
||||
@@ -15,7 +15,7 @@ class JsonAttachment {
|
||||
|
||||
final SignalServiceAttachmentPointer pointer = attachment.asPointer();
|
||||
if (attachment.isPointer()) {
|
||||
this.id = pointer.getId();
|
||||
this.id = String.valueOf(pointer.getId());
|
||||
if (pointer.getFileName().isPresent()) {
|
||||
this.filename = pointer.getFileName().get();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user