mirror of
https://seed.radicle.dev/rad:z4V1sjrXqjvFdnCUbxPFqd5p4DtH5.git
synced 2026-10-27 15:40:36 +08:00
Fix issue sorting and timestamps
Issues should be sorted by creation time and we should show the creation time as the issue timestamp. Otherwise edits will reorder the comment thread.
This commit is contained in:
committed by
Sebastian Martinez
parent
1f9f6505ab
commit
319b1502c6
@@ -115,7 +115,7 @@
|
||||
author={reply.author}
|
||||
caption="replied"
|
||||
reactions={reply.reactions}
|
||||
timestamp={reply.edits.slice(-1)[0].timestamp}
|
||||
timestamp={reply.edits[0].timestamp}
|
||||
body={reply.edits.slice(-1)[0].body}
|
||||
editComment={editComment &&
|
||||
canEditComment(reply.author.did) &&
|
||||
|
||||
@@ -69,10 +69,7 @@
|
||||
root: thread,
|
||||
replies: issue.discussion
|
||||
.filter(comment => comment.replyTo === thread.id)
|
||||
.sort(
|
||||
(a, b) =>
|
||||
a.edits.slice(-1)[0].timestamp - b.edits.slice(-1)[0].timestamp,
|
||||
),
|
||||
.sort((a, b) => a.edits[0].timestamp - b.edits[0].timestamp),
|
||||
};
|
||||
}, []);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user