mirror of
https://github.com/signalapp/Signal-Android.git
synced 2025-12-21 19:48:29 +00:00
Fix handling of stickers with invalid locators in backups.
This commit is contained in:
@@ -4,6 +4,7 @@ import android.net.Uri
|
||||
import android.os.Parcel
|
||||
import org.thoughtcrime.securesms.blurhash.BlurHash
|
||||
import org.thoughtcrime.securesms.database.AttachmentTable
|
||||
import org.thoughtcrime.securesms.stickers.StickerLocator
|
||||
import java.util.UUID
|
||||
|
||||
/**
|
||||
@@ -53,6 +54,7 @@ class TombstoneAttachment : Attachment {
|
||||
voiceNote: Boolean = false,
|
||||
borderless: Boolean = false,
|
||||
gif: Boolean = false,
|
||||
stickerLocator: StickerLocator? = null,
|
||||
quote: Boolean,
|
||||
uuid: UUID?
|
||||
) : super(
|
||||
@@ -76,7 +78,7 @@ class TombstoneAttachment : Attachment {
|
||||
incrementalMacChunkSize = incrementalMacChunkSize ?: 0,
|
||||
uploadTimestamp = 0,
|
||||
caption = caption,
|
||||
stickerLocator = null,
|
||||
stickerLocator = stickerLocator,
|
||||
blurHash = BlurHash.parseOrNull(blurHash),
|
||||
audioHash = null,
|
||||
transformProperties = null,
|
||||
|
||||
@@ -83,6 +83,7 @@ fun FilePointer?.toLocalAttachment(
|
||||
borderless = borderless,
|
||||
gif = gif,
|
||||
quote = false,
|
||||
stickerLocator = stickerLocator,
|
||||
uuid = UuidUtil.fromByteStringOrNull(uuid)
|
||||
)
|
||||
} else if (this.backupLocator != null) {
|
||||
|
||||
Reference in New Issue
Block a user