mirror of https://github.com/M66B/FairEmail.git
Workaround Open-Xchange bug
This commit is contained in:
parent
b98287e68a
commit
bdf8f43628
|
@ -813,7 +813,16 @@ class Core {
|
||||||
searchTerm = new OrTerm(searchTerm, new FlagTerm(new Flags(Flags.Flag.FLAGGED), true));
|
searchTerm = new OrTerm(searchTerm, new FlagTerm(new Flags(Flags.Flag.FLAGGED), true));
|
||||||
|
|
||||||
long search = SystemClock.elapsedRealtime();
|
long search = SystemClock.elapsedRealtime();
|
||||||
Message[] imessages = ifolder.search(searchTerm);
|
Message[] imessages;
|
||||||
|
try {
|
||||||
|
imessages = ifolder.search(searchTerm);
|
||||||
|
} catch (MessagingException ex) {
|
||||||
|
if (ifolder.getPermanentFlags().contains(Flags.Flag.FLAGGED)) {
|
||||||
|
Log.w(ex.getMessage());
|
||||||
|
imessages = ifolder.search(new ReceivedDateTerm(ComparisonTerm.GE, new Date(sync_time)));
|
||||||
|
} else
|
||||||
|
throw ex;
|
||||||
|
}
|
||||||
Log.i(folder.name + " remote count=" + imessages.length +
|
Log.i(folder.name + " remote count=" + imessages.length +
|
||||||
" search=" + (SystemClock.elapsedRealtime() - search) + " ms");
|
" search=" + (SystemClock.elapsedRealtime() - search) + " ms");
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue