@@ -818,7 +818,9 @@ module Routing {
818
818
* A parameter to a route handler function.
819
819
*/
820
820
class RouteHandlerParameter extends DataFlow:: ParameterNode {
821
- RouteHandlerParameter ( ) { this = any ( RouteHandler h ) .getFunction ( ) .getAParameter ( ) }
821
+ private RouteHandler handler ;
822
+
823
+ RouteHandlerParameter ( ) { this = handler .getFunction ( ) .getAParameter ( ) }
822
824
823
825
/** Gets a data flow node referring to this route handler parameter. */
824
826
private DataFlow:: SourceNode ref ( DataFlow:: TypeTracker t ) {
@@ -834,15 +836,15 @@ module Routing {
834
836
/**
835
837
* Gets the corresponding route handler, that is, the function on which this is a parameter.
836
838
*/
837
- final RouteHandler getRouteHandler ( ) { result . getFunction ( ) . getAParameter ( ) = this }
839
+ final RouteHandler getRouteHandler ( ) { result = handler }
838
840
839
841
/**
840
842
* Gets a node that is stored in the given access path on this route handler parameter, either
841
843
* during execution of this router handler, or in one of the preceding ones.
842
844
*/
843
845
pragma [ inline]
844
846
DataFlow:: Node getValueFromAccessPath ( string path ) {
845
- exists ( RouteHandler handler , int i , Node predecessor |
847
+ exists ( int i , Node predecessor |
846
848
pragma [ only_bind_out ] ( this ) = handler .getFunction ( ) .getParameter ( i ) and
847
849
result = getAnAccessPathRhs ( predecessor , i , path ) and
848
850
( handler .isGuardedByNode ( predecessor ) or predecessor = handler )
0 commit comments