From 041e293ac1fa25a02fc8203f2ef277df577001a1 Mon Sep 17 00:00:00 2001 From: M66B Date: Mon, 15 Jul 2019 12:41:31 +0200 Subject: [PATCH] Fallback to sent time if no received time --- app/src/main/java/eu/faircode/email/MessageHelper.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/src/main/java/eu/faircode/email/MessageHelper.java b/app/src/main/java/eu/faircode/email/MessageHelper.java index 2642fcca7b..92d2908e9b 100644 --- a/app/src/main/java/eu/faircode/email/MessageHelper.java +++ b/app/src/main/java/eu/faircode/email/MessageHelper.java @@ -639,6 +639,8 @@ public class MessageHelper { long getReceived() throws MessagingException { Date received = imessage.getReceivedDate(); + if (received == null) + received = imessage.getSentDate(); return (received == null ? new Date() : received).getTime(); }