Skip to content

Commit 1e20607

Browse files
committed
fix: add missing type check
1 parent 9303234 commit 1e20607

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

@commitlint/load/src/utils/load-parser-opts.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,9 @@ export async function loadParserOpts(
2929
}
3030
// Await for the module, loaded with require
3131
const parser = await pendingParser;
32+
if (typeof pendingParser !== 'object') {
33+
return undefined;
34+
}
3235

3336
// Await parser opts if applicable
3437
if (isPromiseLike(parser.parserOpts)) {

0 commit comments

Comments
 (0)