Commit 5d29271d authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Minor optimization

parent 715f411d
Pipeline #37813 passed with stage
in 29 minutes and 16 seconds
......@@ -116,13 +116,14 @@ void ExpireJob::itemFetchResult(KJob *job)
continue;
}
time_t maxTime = status.isRead() ? mMaxReadTime : mMaxUnreadTime;
if (!mb->date(false)) {
auto mailDate = mb->date(false);
if (!mailDate) {
continue;
}
if (mb->date()->dateTime().toSecsSinceEpoch() < maxTime) {
const time_t maxTime = status.isRead() ? mMaxReadTime : mMaxUnreadTime;
if (mailDate->dateTime().toSecsSinceEpoch() < maxTime) {
mRemovedMsgs.append(item);
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment