Skip to content

Commit ccb0192

Browse files
committed
refactor: fiddingl
1 parent 44d4ac9 commit ccb0192

1 file changed

Lines changed: 3 additions & 7 deletions

File tree

src/utils.ts

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -93,14 +93,10 @@ export function formatErrors(
9393
if (loaderOptions.ignoreDiagnostics.indexOf(diagnostic.code) !== -1) {
9494
return false;
9595
}
96-
if (matchesReportFiles !== null && diagnostic.file !== undefined) {
97-
const relativeFileName = path.relative(
98-
context,
99-
diagnostic.file.fileName,
100-
);
101-
if (!matchesReportFiles(relativeFileName)) {
96+
if (matchesReportFiles !== null &&
97+
diagnostic.file !== undefined &&
98+
!matchesReportFiles(path.relative(context, diagnostic.file.fileName))) {
10299
return false;
103-
}
104100
}
105101
return true;
106102
})

0 commit comments

Comments
 (0)