Skip to content

Commit 5fd4c7a

Browse files
committed
use PartialInvokeNode
1 parent bef0925 commit 5fd4c7a

File tree

1 file changed

+2
-5
lines changed
  • javascript/ql/src/semmle/javascript/frameworks

1 file changed

+2
-5
lines changed

javascript/ql/src/semmle/javascript/frameworks/Express.qll

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -111,11 +111,8 @@ module Express {
111111
exists(HTTP::RouteHandlerCandidateContainer container | pred = container.getRouteHandler(succ))
112112
or
113113
// (function (req, res) {}).bind(this);
114-
exists(DataFlow::MethodCallNode call |
115-
call.getMethodName() = "bind" and call.getNumArgument() = 1
116-
|
117-
succ = call and
118-
pred = call.getReceiver().getALocalSource()
114+
exists(DataFlow::PartialInvokeNode call |
115+
succ = call.getBoundFunction(pred, 0)
119116
)
120117
}
121118

0 commit comments

Comments
 (0)