File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11import * as vscode from 'vscode'
22import * as fs from 'fs'
3- import { groupBy , startCase } from 'lodash'
3+ import { groupBy , startCase , uniqBy } from 'lodash'
44import { CodacyCloud } from '../git/CodacyCloud'
55import { PullRequestIssue } from '../git/PullRequest'
66import { GitProvider } from '../git/GitProvider'
@@ -156,7 +156,7 @@ export class ProblemsDiagnosticCollection implements vscode.Disposable {
156156 this . _collection . clear ( )
157157 const filesWithApiIssues = Object . keys ( this . _currentApiIssues ) . map ( ( key ) => ( { file : key , isCliIssue : false } ) )
158158 const filesWithCliIssues = Object . keys ( this . _currentCliIssues ) . map ( ( key ) => ( { file : key , isCliIssue : true } ) )
159- const allFiles = [ ... new Set ( [ ...filesWithApiIssues , ...filesWithCliIssues ] ) ]
159+ const allFiles = uniqBy ( [ ...filesWithApiIssues , ...filesWithCliIssues ] , 'file' )
160160 allFiles . forEach ( ( { file, isCliIssue } ) => {
161161 const document = vscode . workspace . textDocuments . find ( ( doc ) => doc . uri . fsPath === file )
162162 if ( document ) {
You can’t perform that action at this time.
0 commit comments