From e486d485561233fd1baf2e36954067b6d1bb7d90 Mon Sep 17 00:00:00 2001 From: Chi Vinh Le Date: Sat, 29 Apr 2017 01:02:59 +0700 Subject: [PATCH] postComment should increase replyCount --- client/coral-framework/graphql/mutations/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/coral-framework/graphql/mutations/index.js b/client/coral-framework/graphql/mutations/index.js index eb0b5386a..b1ea57ae1 100644 --- a/client/coral-framework/graphql/mutations/index.js +++ b/client/coral-framework/graphql/mutations/index.js @@ -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; }) }