Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(angular): update function call broken by Angular changes #857

Merged
merged 4 commits into from Sep 25, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
12 changes: 6 additions & 6 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Expand Up @@ -62,8 +62,8 @@
},
"homepage": "https://github.com/mgechev/codelyzer#readme",
"devDependencies": {
"@angular/compiler": "8.1.3",
"@angular/core": "8.1.3",
"@angular/compiler": "8.2.0",
"@angular/core": "8.2.0",
"@commitlint/cli": "8.1.0",
"@commitlint/config-angular": "8.1.0",
"@types/chai": "4.2.2",
Expand Down
2 changes: 1 addition & 1 deletion src/templateConditionalComplexityRule.ts
Expand Up @@ -54,7 +54,7 @@ export const getFailureMessage = (totalComplexity: number, maxComplexity = Rule.
const getTotalComplexity = (ast: AST): number => {
const expr = ((ast as ASTWithSource).source || '').replace(/\s/g, '');
const expressionParser = new Parser(new Lexer());
const astWithSource = expressionParser.parseAction(expr, null);
const astWithSource = expressionParser.parseAction(expr, null, 0);
const conditions: Binary[] = [];
let totalComplexity = 0;
let condition = astWithSource.ast as Binary;
Expand Down