sorted comments by timestamp

This commit is contained in:
plebbitor
2023-03-06 13:33:46 +01:00
parent 356b0739fd
commit 01e06258d9
2 changed files with 5 additions and 2 deletions
+1
View File
@@ -22,6 +22,7 @@ function renderComments(comments) {
};
const renderedComments = comments.flatMap(renderComment);
renderedComments.sort((a, b) => a.timestamp - b.timestamp);
return { renderedComments, omittedCount };
}