| Conditions | 2 |
| Paths | 2 |
| Total Lines | 22 |
| Code Lines | 14 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 25 | public function process(ContainerBuilder $container) |
||
| 26 | { |
||
| 27 | if (!$container->hasDefinition('metadata_endpoint_pipe')) { |
||
| 28 | return; |
||
| 29 | } |
||
| 30 | |||
| 31 | $path = $container->getParameter('oauth2_server.endpoint.metadata.path'); |
||
| 32 | $route_loader = $container->getDefinition(RouteLoader::class); |
||
| 33 | $route_loader->addMethodCall('addRoute', [ |
||
| 34 | 'metadata_endpoint', |
||
| 35 | 'metadata_endpoint_pipe', |
||
| 36 | 'dispatch', |
||
| 37 | $path, // path |
||
| 38 | [], // defaults |
||
| 39 | [], // requirements |
||
| 40 | [], // options |
||
| 41 | '', // host |
||
| 42 | ['https'], // schemes |
||
| 43 | ['GET'], // methods |
||
| 44 | '', // condition |
||
| 45 | ]); |
||
| 46 | } |
||
| 47 | } |
||
| 48 |