mirror of https://github.com/M66B/FairEmail.git
Handle uid not found
This commit is contained in:
parent
e6f7063dd9
commit
9c13f2d97f
|
@ -752,6 +752,8 @@ class Core {
|
|||
if (imessages != null && imessages.length > 0)
|
||||
try {
|
||||
Message imessage = ifolder.getMessageByUID(message.uid);
|
||||
if (imessage == null)
|
||||
throw new MessageRemovedException();
|
||||
imessage.setFlag(Flags.Flag.DELETED, true);
|
||||
ifolder.expunge();
|
||||
} catch (MessagingException ex) {
|
||||
|
@ -1032,6 +1034,8 @@ class Core {
|
|||
if (uid != null) {
|
||||
if (draft) {
|
||||
Message icopy = itarget.getMessageByUID(uid);
|
||||
if (icopy == null)
|
||||
continue;
|
||||
|
||||
// Mark read
|
||||
if (seen && !icopy.isSet(Flags.Flag.SEEN) && flags.contains(Flags.Flag.SEEN))
|
||||
|
|
Loading…
Reference in New Issue