From 7618dd949f1b6758b2e9e29dfe2cc435783926f7 Mon Sep 17 00:00:00 2001 From: M66B Date: Mon, 19 Jul 2021 07:11:42 +0200 Subject: [PATCH] Skip reporting removed raw messages --- app/src/main/java/eu/faircode/email/Core.java | 24 ++++++++++--------- 1 file changed, 13 insertions(+), 11 deletions(-) diff --git a/app/src/main/java/eu/faircode/email/Core.java b/app/src/main/java/eu/faircode/email/Core.java index 1ab9da3407..6eb0ead5c2 100644 --- a/app/src/main/java/eu/faircode/email/Core.java +++ b/app/src/main/java/eu/faircode/email/Core.java @@ -620,17 +620,19 @@ class Core { ops.remove(op); - int resid = context.getResources().getIdentifier( - "title_op_title_" + op.name, - "string", - context.getPackageName()); - String title = (resid == 0 ? null : context.getString(resid)); - if (title != null) { - NotificationCompat.Builder builder = - getNotificationError(context, "warning", title, ex); - nm.notify(op.name + ":" + op.message, - NotificationHelper.NOTIFICATION_TAGGED, - builder.build()); + if (!MessageHelper.isRemoved(ex)) { + int resid = context.getResources().getIdentifier( + "title_op_title_" + op.name, + "string", + context.getPackageName()); + String title = (resid == 0 ? null : context.getString(resid)); + if (title != null) { + NotificationCompat.Builder builder = + getNotificationError(context, "warning", title, ex); + nm.notify(op.name + ":" + op.message, + NotificationHelper.NOTIFICATION_TAGGED, + builder.build()); + } } } else {