chore(typescript): Enabled noFallthroughCasesInSwitch
Turned on the noFallthroughCasesInSwitch flag in tsconfig and fixed a few cases where there were fallthroughs.
This commit is contained in:
@ -64,9 +64,8 @@ export class MetadataCollector {
|
||||
let isConstructor = false;
|
||||
switch (member.kind) {
|
||||
case ts.SyntaxKind.Constructor:
|
||||
isConstructor = true;
|
||||
// fallthrough
|
||||
case ts.SyntaxKind.MethodDeclaration:
|
||||
isConstructor = member.kind === ts.SyntaxKind.Constructor;
|
||||
const method = <ts.MethodDeclaration|ts.ConstructorDeclaration>member;
|
||||
const methodDecorators = getDecorators(method.decorators);
|
||||
const parameters = method.parameters;
|
||||
|
@ -176,6 +176,8 @@ export class Evaluator {
|
||||
case ts.SyntaxKind.BarBarToken:
|
||||
return this.isFoldableWorker(binaryExpression.left, folding) &&
|
||||
this.isFoldableWorker(binaryExpression.right, folding);
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
case ts.SyntaxKind.PropertyAccessExpression:
|
||||
const propertyAccessExpression = <ts.PropertyAccessExpression>node;
|
||||
|
Reference in New Issue
Block a user