File tree Expand file tree Collapse file tree 2 files changed +4
-9
lines changed Expand file tree Collapse file tree 2 files changed +4
-9
lines changed Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ export const fsFileSystem: FileSystem = {
15
15
try {
16
16
const stat = await fs . promises . stat ( filePath ) ;
17
17
return stat . isDirectory ( ) ;
18
- } catch ( error ) {
18
+ } catch {
19
19
return false ;
20
20
}
21
21
} ,
Original file line number Diff line number Diff line change 4
4
findTypeScriptConfiguration ,
5
5
TypeScriptConfiguration ,
6
6
} from "../input/findTypeScriptConfiguration" ;
7
- import { uniqueFromSources } from "../utils" ;
7
+ import { isTruthy , uniqueFromSources } from "../utils" ;
8
8
9
9
export type CollectCommentFileNamesDependencies = {
10
10
findTypeScriptConfiguration : SansDependencies < typeof findTypeScriptConfiguration > ;
@@ -38,13 +38,8 @@ export const collectCommentFileNames = async (
38
38
const includeListFiles = (
39
39
await Promise . all ( includeList . map ( dependencies . fileSystem . directoryExists ) )
40
40
)
41
- . map ( ( isDirectory , i ) => {
42
- if ( isDirectory ) {
43
- return null ;
44
- }
45
- return includeList [ i ] ;
46
- } )
47
- . filter ( ( item ) : item is string => typeof item === "string" ) ;
41
+ . map ( ( isDirectory , i ) => ! isDirectory && includeList [ i ] )
42
+ . filter ( isTruthy ) ;
48
43
49
44
return {
50
45
exclude : typescriptConfiguration . exclude ,
You can’t perform that action at this time.
0 commit comments