COMM: correctly use the ascendingTimestampOrder flag when retrieving new COMM messages. this matches the stock intel site, and prevents gaps occuring when filling in entries after resuming from idle

related to #656 no 2
This commit is contained in:
Jon Atkins 2013-11-24 01:32:46 +00:00
parent 1501f98f9b
commit d58ba079b8

View File

@ -106,6 +106,9 @@ window.chat.genPostData = function(isFaction, storageHash, getOlderMsgs) {
// Currently this edge case is not handled. Lets see if this is a // Currently this edge case is not handled. Lets see if this is a
// problem in crowded areas. // problem in crowded areas.
$.extend(data, {minTimestampMs: min}); $.extend(data, {minTimestampMs: min});
// when requesting with an acutal minimum timestamp, request oldest rather than newest first.
// this matches the stock intel site, and ensures no gaps when continuing after an extended idle period
if (min > -1) $.extend(data, {ascendingTimestampOrder: true});
} }
return data; return data;
} }