From ea449aeec65fc85c3d398ba79478760ce78b9d90 Mon Sep 17 00:00:00 2001 From: M66B Date: Thu, 4 Jul 2024 09:16:13 +0200 Subject: [PATCH] POP3: reload on changing leave options --- app/src/main/java/eu/faircode/email/FragmentPop.java | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/app/src/main/java/eu/faircode/email/FragmentPop.java b/app/src/main/java/eu/faircode/email/FragmentPop.java index 4c5032a79d..fee85e89dd 100644 --- a/app/src/main/java/eu/faircode/email/FragmentPop.java +++ b/app/src/main/java/eu/faircode/email/FragmentPop.java @@ -658,6 +658,12 @@ public class FragmentPop extends FragmentBase { BuildConfig.DEBUG)); Log.i("Account check=" + check); + boolean reload = (synchronize && !ondemand && account != null && + (account.leave_on_server != leave_server || + account.client_delete != client_delete || + account.leave_deleted != leave_deleted || + account.leave_on_device != leave_device)); + Long last_connected = null; if (account != null && synchronize == account.synchronize) last_connected = account.last_connected; @@ -777,6 +783,8 @@ public class FragmentPop extends FragmentBase { if (reschedule) ServiceSynchronize.reschedule(context); + else if (reload) + ServiceSynchronize.reload(context, account.id, false, "POP3 leave"); else ServiceSynchronize.eval(context, "POP3");