Skip to content

Commit

Permalink
Count replies, not comments (#209527)
Browse files Browse the repository at this point in the history
  • Loading branch information
alexr00 authored Apr 4, 2024
1 parent 8012a40 commit ae1a6d6
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -232,8 +232,10 @@ export class CommentNodeRenderer implements IListRenderer<ITreeNode<CommentNode>
}

private getCountString(commentCount: number): string {
if (commentCount > 1) {
return nls.localize('commentsCount', "{0} comments", commentCount);
if (commentCount > 2) {
return nls.localize('commentsCountReplies', "{0} replies", commentCount - 1);
} else if (commentCount === 2) {
return nls.localize('commentsCountReply', "1 reply");
} else {
return nls.localize('commentCount', "1 comment");
}
Expand Down

0 comments on commit ae1a6d6

Please sign in to comment.