Fix sms export crash with missing sms thread recipient.

This commit is contained in:
Cody Henthorne 2022-10-18 12:34:30 -04:00
parent b324db53d3
commit f0e94ebbad

View file

@ -180,9 +180,9 @@ class SignalSmsExportReader(
}
private fun readExportableSmsMessageFromRecord(record: MessageRecord, exportState: MessageExportState): ExportableMessage {
val threadRecipient = SignalDatabase.threads.getRecipientForThreadId(record.threadId)!!
val threadRecipient = SignalDatabase.threads.getRecipientForThreadId(record.threadId)
return if (threadRecipient.isMmsGroup) {
return if (threadRecipient?.isMmsGroup == true) {
readExportableMmsMessageFromRecord(record, exportState)
} else {
ExportableMessage.Sms(