diff --git a/javascript/ql/lib/semmle/javascript/dataflow/Nodes.qll b/javascript/ql/lib/semmle/javascript/dataflow/Nodes.qll index 22e8511509a..52547d5f590 100644 --- a/javascript/ql/lib/semmle/javascript/dataflow/Nodes.qll +++ b/javascript/ql/lib/semmle/javascript/dataflow/Nodes.qll @@ -1309,8 +1309,7 @@ module ClassNode { result = method.getBody().flow() ) or - // ES6 class property in constructor - astNode instanceof ClassDefinition and + // ES6 class property or Function-style class methods via constructor kind = MemberKind::method() and exists(ThisNode receiver | receiver = this.getConstructor().getReceiver() and @@ -1324,14 +1323,6 @@ module ClassNode { proto.hasPropertyWrite(name, result) ) or - // Function-style class methods via constructor - astNode instanceof Function and - kind = MemberKind::method() and - exists(ThisNode receiver | - receiver = this.getConstructor().getReceiver() and - receiver.hasPropertyWrite(name, result) - ) - or // Function-style class accessors astNode instanceof Function and exists(PropertyAccessor accessor | @@ -1351,8 +1342,7 @@ module ClassNode { result = method.getBody().flow() ) or - // ES6 class property in constructor - astNode instanceof ClassDefinition and + // ES6 class property or Function-style class methods via constructor kind = MemberKind::method() and exists(ThisNode receiver | receiver = this.getConstructor().getReceiver() and @@ -1366,14 +1356,6 @@ module ClassNode { result = proto.getAPropertySource() ) or - // Function-style class methods via constructor - astNode instanceof Function and - kind = MemberKind::method() and - exists(ThisNode receiver | - receiver = this.getConstructor().getReceiver() and - result = receiver.getAPropertySource() - ) - or // Function-style class accessors astNode instanceof Function and exists(PropertyAccessor accessor |