Fix compile errors introduced by typescript 4.4.2
4.4.2 introduces a breaking change that the variable in a catch clause is now `unknown` type. So, we need to cast the `e`, `err`, or `error` variables to type `Error`.
This commit is contained in:
parent
5b28adb7ed
commit
40568daca8
83 changed files with 601 additions and 576 deletions
|
|
@ -302,8 +302,10 @@ export async function runQueries(
|
|||
logger.info(analysisSummary);
|
||||
printLinesOfCodeSummary(logger, language, await locPromise);
|
||||
} catch (e) {
|
||||
logger.info(e);
|
||||
logger.info(e.stack);
|
||||
logger.info(String(e));
|
||||
if (e instanceof Error) {
|
||||
logger.info(e.stack!);
|
||||
}
|
||||
statusReport.analyze_failure_language = language;
|
||||
throw new CodeQLAnalysisError(
|
||||
statusReport,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue