From 5642d940644a779d3fdf486557ec1d298f98513d Mon Sep 17 00:00:00 2001 From: M66B Date: Mon, 10 Oct 2022 14:03:49 +0200 Subject: [PATCH] Server search improvements --- .../email/BoundaryCallbackMessages.java | 57 ++++++++++--------- 1 file changed, 29 insertions(+), 28 deletions(-) diff --git a/app/src/main/java/eu/faircode/email/BoundaryCallbackMessages.java b/app/src/main/java/eu/faircode/email/BoundaryCallbackMessages.java index cb190df0b2..90d4673b43 100644 --- a/app/src/main/java/eu/faircode/email/BoundaryCallbackMessages.java +++ b/app/src/main/java/eu/faircode/email/BoundaryCallbackMessages.java @@ -100,7 +100,6 @@ public class BoundaryCallbackMessages extends PagedList.BoundaryCallback() { - @Override - public int compare(Message m1, Message m2) { - Date d1 = null; - try { - d1 = m1.getReceivedDate(); - } catch (Throwable ex) { - Log.w(ex); - } - - Date d2 = null; - try { - d2 = m2.getReceivedDate(); - } catch (Throwable ex) { - Log.w(ex); - } - - return Long.compare(d1 == null ? 0 : d1.getTime(), d2 == null ? 0 : d2.getTime()); - } - }); } catch (MessagingException ex) { if (ex.getCause() instanceof ProtocolException) throw (ProtocolException) ex.getCause(); @@ -654,6 +628,33 @@ public class BoundaryCallbackMessages extends PagedList.BoundaryCallback