From 56e727d2821fc7c040696b7957ae425192bc5652 Mon Sep 17 00:00:00 2001 From: M66B Date: Wed, 25 Oct 2023 17:51:39 +0200 Subject: [PATCH] Process calendar events in the sent-messages folder too --- app/src/main/java/eu/faircode/email/MessageHelper.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/app/src/main/java/eu/faircode/email/MessageHelper.java b/app/src/main/java/eu/faircode/email/MessageHelper.java index 90537c796b..cb205fdde7 100644 --- a/app/src/main/java/eu/faircode/email/MessageHelper.java +++ b/app/src/main/java/eu/faircode/email/MessageHelper.java @@ -4427,18 +4427,19 @@ public class MessageHelper { EntityFolder folder = (message == null ? null : db.folder().getFolder(message.folder)); EntityAccount account = (folder == null ? null : db.account().getAccount(folder.account)); + boolean sent = (folder != null && EntityFolder.SENT.equals(folder.type)); boolean received = (folder != null && (EntityFolder.INBOX.equals(folder.type) || EntityFolder.SYSTEM.equals(folder.type) || EntityFolder.USER.equals(folder.type))); - if (!permission || !received || account == null || account.calendar == null) { + if (!permission || !(sent || received) || account == null || account.calendar == null) { EntityLog.log(context, "Event not processed" + " permission=" + permission + " account=" + (account != null) + " calendar=" + (account == null ? null : account.calendar) + " folder=" + (folder != null) + ":" + (folder == null ? null : folder.type) + - " received=" + received); + " sent=" + sent + " received=" + received); return; }