mirror of
https://github.com/SimpleMobileTools/Simple-SMS-Messenger.git
synced 2025-01-24 06:06:56 +01:00
lets always use the system milliseconds at setting received message time
it.timestampMillis seems to ignore seconds, which can mix up messages
This commit is contained in:
parent
60d06be5bd
commit
36a09ac8cb
@ -21,7 +21,6 @@ import com.simplemobiletools.smsmessenger.R
|
||||
import com.simplemobiletools.smsmessenger.extensions.*
|
||||
import com.simplemobiletools.smsmessenger.helpers.refreshMessages
|
||||
import com.simplemobiletools.smsmessenger.models.Message
|
||||
import kotlin.math.min
|
||||
|
||||
class SmsReceiver : BroadcastReceiver() {
|
||||
override fun onReceive(context: Context, intent: Intent) {
|
||||
@ -43,7 +42,7 @@ class SmsReceiver : BroadcastReceiver() {
|
||||
subject = it.pseudoSubject
|
||||
status = it.status
|
||||
body += it.messageBody
|
||||
date = min(it.timestampMillis, System.currentTimeMillis())
|
||||
date = System.currentTimeMillis()
|
||||
threadId = context.getThreadId(address)
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user