mirror of
https://github.com/github/codeql.git
synced 2026-04-28 10:15:14 +02:00
JS: Remove duplicate PromiseFlowStep
This commit is contained in:
@@ -4,23 +4,6 @@
|
||||
|
||||
import javascript
|
||||
|
||||
/**
|
||||
* A data flow edge from a promise reaction to the corresponding handler.
|
||||
*/
|
||||
private class PromiseFlowStep extends DataFlow::AdditionalFlowStep {
|
||||
PromiseDefinition p;
|
||||
|
||||
PromiseFlowStep() { this = p }
|
||||
|
||||
override predicate step(DataFlow::Node pred, DataFlow::Node succ) {
|
||||
pred = p.getResolveParameter().getACall().getArgument(0) and
|
||||
succ = p.getAResolveHandler().getParameter(0)
|
||||
or
|
||||
pred = p.getRejectParameter().getACall().getArgument(0) and
|
||||
succ = p.getARejectHandler().getParameter(0)
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Holds if taint propagates from `pred` to `succ` through promises.
|
||||
*/
|
||||
|
||||
@@ -142,7 +142,7 @@ private class ES2015PromiseDefinition extends PromiseDefinition, DataFlow::NewNo
|
||||
/**
|
||||
* A data flow edge from a promise reaction to the corresponding handler.
|
||||
*/
|
||||
private class PromiseFlowStep extends DataFlow::AdditionalFlowStep {
|
||||
private class PromiseFlowStep extends DataFlow::AdditionalFlowStep {
|
||||
PromiseDefinition p;
|
||||
|
||||
PromiseFlowStep() { this = p }
|
||||
|
||||
Reference in New Issue
Block a user