Skip to content

Commit c7bf06b

Browse files
committed
Merge pull request #1 from OndraM/import-routes
Routes should be just imported, not mounted
2 parents 425bbbe + 180240d commit c7bf06b

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

MicroKernel.php

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -39,14 +39,11 @@ public function registerBundles()
3939
protected function configureRoutes(RouteCollectionBuilder $routes)
4040
{
4141
if (in_array($this->getEnvironment(), array('dev', 'test'), true)) {
42-
$routes->mount('/_wdt', $routes->import('@WebProfilerBundle/Resources/config/routing/wdt.xml'));
43-
$routes->mount(
44-
'/_profiler',
45-
$routes->import('@WebProfilerBundle/Resources/config/routing/profiler.xml')
46-
);
42+
$routes->import('@WebProfilerBundle/Resources/config/routing/wdt.xml', '/_wdt');
43+
$routes->import('@WebProfilerBundle/Resources/config/routing/profiler.xml', '/_profiler');
4744
}
4845

49-
$routes->mount('/', $routes->import('@AppBundle/Controller', 'annotation'));
46+
$routes->import('@AppBundle/Controller', '/', 'annotation');
5047
}
5148

5249
/*

0 commit comments

Comments
 (0)