Merge branch 'fix/reply-count' into 'develop'

fix: Replying to a post sometimes doesn't increase post's reply count

Co-authored-by: Lhcfl <Lhcfl@outlook.com>

See merge request firefish/firefish!10764
This commit is contained in:
naskya 2024-04-24 06:02:37 +00:00
commit fbd980aeb8
2 changed files with 1 additions and 1 deletions

View file

@ -278,7 +278,6 @@ useNoteCapture({
note,
isDeletedRef: isDeleted,
onReplied: (replyNote) => {
note.value.repliesCount += 1;
repliesPagingComponent.value?.append(replyNote);
},
});

View file

@ -21,6 +21,7 @@ export function useNoteCapture(props: {
switch (type) {
case "replied": {
note.value.repliesCount += 1;
if (props.onReplied) {
const { id: createdId } = body;
const replyNote = await os.api("notes/show", {