mirror of
https://github.com/M66B/FairEmail.git
synced 2026-04-04 16:16:33 +02:00
POP3 optimization
This commit is contained in:
@@ -2343,6 +2343,14 @@ class Core {
|
||||
uidlMsgId.put(id.uidl, id.msgid);
|
||||
}
|
||||
|
||||
Map<String, TupleUidl> msgIdTuple = new HashMap<>();
|
||||
for (TupleUidl id : ids)
|
||||
if (id.msgid != null) {
|
||||
if (msgIdTuple.containsKey(id.msgid))
|
||||
Log.w(account.name + " POP duplicate msgid=" + id.msgid);
|
||||
msgIdTuple.put(id.msgid, id);
|
||||
}
|
||||
|
||||
// Fetch UIDLs
|
||||
if (hasUidl) {
|
||||
FetchProfile ifetch = new FetchProfile();
|
||||
@@ -2431,7 +2439,7 @@ class Core {
|
||||
continue;
|
||||
}
|
||||
|
||||
if (db.message().countMessageByMsgId(folder.id, msgid) > 0) {
|
||||
if (msgIdTuple.containsKey(msgid)) {
|
||||
_new = false;
|
||||
Log.i(account.name + " POP having " + msgid + "/" + uidl);
|
||||
continue;
|
||||
|
||||
Reference in New Issue
Block a user