From 147bf957d88f9cfd95a48388a5da08624ea0e360 Mon Sep 17 00:00:00 2001 From: M66B Date: Sun, 25 Nov 2018 11:59:19 +0100 Subject: [PATCH] Explicitly unhide on sync --- .../main/java/eu/faircode/email/ServiceSynchronize.java | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/app/src/main/java/eu/faircode/email/ServiceSynchronize.java b/app/src/main/java/eu/faircode/email/ServiceSynchronize.java index 8803622e94..2e2dff2ffa 100644 --- a/app/src/main/java/eu/faircode/email/ServiceSynchronize.java +++ b/app/src/main/java/eu/faircode/email/ServiceSynchronize.java @@ -1959,11 +1959,10 @@ public class ServiceSynchronize extends LifecycleService { String thread = helper.getThreadId(uid); Log.i(Helper.TAG, folder.name + " found as id=" + dup.id + "/" + uid + " msgid=" + msgid + " thread=" + thread); - dup.folder = folder.id; + dup.folder = folder.id; // From outbox dup.uid = uid; dup.msgid = msgid; dup.thread = thread; - dup.ui_hide = false; dup.error = null; db.message().updateMessage(dup); message = dup; @@ -2083,6 +2082,12 @@ public class ServiceSynchronize extends LifecycleService { db.message().updateMessage(message); Log.i(Helper.TAG, folder.name + " updated id=" + message.id + " uid=" + message.uid + " flagged=" + flagged); } + + if (message.ui_hide) { + message.ui_hide = false; + db.message().updateMessage(message); + Log.i(Helper.TAG, folder.name + " updated id=" + message.id + " uid=" + message.uid + " unhide"); + } } return message.id;