$args = array
();
foreach ( $matches as $param =>
$value ) { if ( !
is_int( $param ) ) { $args[ $param ] =
$value;
} } foreach ( $endpoints as $endpoint ) { // Remove the redundant preg_match() argument.
unset( $args[0
] );
$request->
set_url_params( $args );
$request->
set_attributes( $endpoint );
} $data =
$handler->
get_data_for_route( $route,
$endpoints, 'help'
);
$response->
set_matched_route( $route );
break;
} $response->
set_data( $data );
return $response;
}