mirror of
https://github.com/github/codeql.git
synced 2026-05-01 19:55:15 +02:00
Generalize the server definition in plugin registration
This commit is contained in:
@@ -20,11 +20,11 @@ module Hapi {
|
||||
// `register (server, options)`
|
||||
// `module.exports.plugin = {register, pkg};`
|
||||
this =
|
||||
any(NodeModule m)
|
||||
any(Module m)
|
||||
.getAnExportedValue("plugin")
|
||||
.(DataFlow::ObjectLiteralNode)
|
||||
.getALocalSource()
|
||||
.getAPropertySource("register")
|
||||
.(DataFlow::FunctionNode)
|
||||
.getAFunctionValue()
|
||||
.getParameter(0)
|
||||
or
|
||||
// `const after = function (server) {...};`
|
||||
|
||||
Reference in New Issue
Block a user