mirror of
https://github.com/wassname/talk.git
synced 2026-07-13 17:45:56 +08:00
postComment should increase replyCount
This commit is contained in:
@@ -57,7 +57,7 @@ export const postComment = graphql(POST_COMMENT, {
|
||||
...oldData.asset,
|
||||
comments: oldData.asset.comments.map((oldComment) => {
|
||||
return oldComment.id === parent_id
|
||||
? {...oldComment, replies: [...oldComment.replies, comment]}
|
||||
? {...oldComment, replies: [...oldComment.replies, comment], replyCount: oldComment.replyCount + 1}
|
||||
: oldComment;
|
||||
})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user