Skip to content
Snippets Groups Projects
Commit 96a85010 authored by deuce's avatar deuce
Browse files

Handle the possiblity of the same date being in the dates array more than

once.
parent bee29af4
No related branches found
No related tags found
No related merge requests found
......@@ -476,11 +476,13 @@ function getMessageThreads(sub, max) {
threads.dates.sort(function (a,b) {return b - a});
for(var d = 0; d < threads.dates.length; d++) {
for(var t in threads.thread) {
if(threads.thread[t].newest != threads.dates[d])
continue;
threads.order.push(t);
break;
if(threads.dates[d] !== threads.dates[d+1]) {
for(var t in threads.thread) {
if(threads.thread[t].newest != threads.dates[d])
continue;
threads.order.push(t);
break;
}
}
}
log(LOG_INFO, "Messages threaded in " + (system.timer - stime) + " seconds.");
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment