Fix sort, this was reversed

This commit is contained in:
Lim Chee Aun 2023-05-10 10:02:50 +08:00
parent 4d5c0f1f5d
commit b8d7e18371

View file

@ -119,8 +119,8 @@ export function groupContext(items) {
// Sort items by checking inReplyToId
contexts.forEach((context) => {
context.sort((a, b) => {
if (a.inReplyToId === b.id) return -1;
if (b.inReplyToId === a.id) return 1;
if (a.inReplyToId === b.id) return 1;
if (b.inReplyToId === a.id) return -1;
return 0;
});
});