Output attachment id as json string to prevent rounding due to conversion to double

Fixes #226
This commit is contained in:
AsamK 2019-09-29 11:21:15 +02:00
parent 9aa13e92fe
commit e490604d43

View file

@ -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();
}