diff --git a/app/src/main/java/eu/faircode/email/ServiceSend.java b/app/src/main/java/eu/faircode/email/ServiceSend.java index aec36e2cef..486e15a2d5 100644 --- a/app/src/main/java/eu/faircode/email/ServiceSend.java +++ b/app/src/main/java/eu/faircode/email/ServiceSend.java @@ -99,6 +99,9 @@ public class ServiceSend extends ServiceBase { } catch (Throwable ex) { Log.w(ex); } + + if (unsent == null || unsent.count == 0) + stopSelf(); } } }); @@ -110,9 +113,6 @@ public class ServiceSend extends ServiceBase { if (operations == null) operations = new ArrayList<>(); - if (operations.size() == 0) - stopSelf(); - final List process = new ArrayList<>(); List ops = new ArrayList<>();