|
@@ -53,7 +53,7 @@ class CommentTransformer extends TransformerAbstract
|
|
|
'avatar' => $user['avatar'],
|
|
|
'content' => $postComment['is_delete']?'该评论已被删除':$postComment['content'],
|
|
|
'created_at' => Carbon::parse($postComment['created_at'])->diffForHumans(),
|
|
|
- 'reply_count' => PostComment::where('parent_id', $postComment['id'])->count(),
|
|
|
+ 'reply_count' => $postComment['reply_count'],
|
|
|
'reply' => $reply,
|
|
|
'is_delete' => $postComment['is_delete'],
|
|
|
];
|