Replies to replies are children of the root comment.

This commit is contained in:
David Jay
2017-01-24 12:37:50 -05:00
parent 33d274386a
commit 75bcf29154
+3 -2
View File
@@ -62,6 +62,7 @@ class Comment extends React.Component {
render () {
const {
comment,
parentId,
currentUser,
asset,
depth,
@@ -101,7 +102,7 @@ class Comment extends React.Component {
console.log('reply button click');
this.setState({replyBoxVisible: !this.state.replyBoxVisible});
}}
parentCommentId={comment.id}
parentCommentId={parentId || comment.id}
currentUserId={currentUser.id}
banned={false} />
<LikeButton
@@ -133,7 +134,7 @@ class Comment extends React.Component {
{
this.state.replyBoxVisible
? <ReplyBox
parentId={comment.id}
parentId={parentId || comment.id}
addNotification={addNotification}
authorId={currentUser.id}
postItem={postItem}