diff --git a/.github/issue-branch.yml b/.github/issue-branch.yml new file mode 100644 index 0000000000..c50919ad70 --- /dev/null +++ b/.github/issue-branch.yml @@ -0,0 +1,9 @@ +branchName: full +silent: false +autoCloseIssue: true + +branches: + - label: enhancement + prefix: feature/ + - label: bug + prefix: bugfix/ diff --git a/src/view/treeNodes/fileChangeNode.ts b/src/view/treeNodes/fileChangeNode.ts index bbc2ed6c3b..0b37bebf6d 100644 --- a/src/view/treeNodes/fileChangeNode.ts +++ b/src/view/treeNodes/fileChangeNode.ts @@ -166,7 +166,7 @@ export class FileChangeNode extends TreeNode implements vscode.TreeItem { updateShowOptions() { const reviewThreads = this.pullRequest.reviewThreadsCache; - const reviewThreadsForNode = reviewThreads.filter(thread => !thread.isDeleted && thread.path === this.fileName); + let reviewThreadsForNode = reviewThreads.filter(thread => !thread.isDeleted && thread.path === this.fileName); DecorationProvider.updateFileComments( this.resourceUri, @@ -174,6 +174,8 @@ export class FileChangeNode extends TreeNode implements vscode.TreeItem { this.fileName, reviewThreadsForNode.length > 0, ); + /* Some comments are attached to the file and have not reference/selection in the content. Need to be removed here. */ + reviewThreadsForNode = reviewThreadsForNode.filter((thread) => thread.line !== undefined); if (reviewThreadsForNode.length) { reviewThreadsForNode.sort((a, b) => a.line - b.line);