[WebProfilerBundle] removed dependency on FrameworkBundle (closes #6949)
This commit is contained in:
parent
3d564ee823
commit
a9f60f70a6
@ -52,6 +52,18 @@ class ProfilerController
|
|||||||
$this->toolbarPosition = $toolbarPosition;
|
$this->toolbarPosition = $toolbarPosition;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Redirects to the last profiles.
|
||||||
|
*
|
||||||
|
* @return RedirectResponse A RedirectResponse instance
|
||||||
|
*/
|
||||||
|
public function homeAction()
|
||||||
|
{
|
||||||
|
$this->profiler->disable();
|
||||||
|
|
||||||
|
return new RedirectResponse($this->generator->generate('_profiler_search_results', array('token' => 'empty', 'limit' => 10)));
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Renders a profiler panel for the given token.
|
* Renders a profiler panel for the given token.
|
||||||
*
|
*
|
||||||
|
@ -4,6 +4,10 @@
|
|||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://symfony.com/schema/routing http://symfony.com/schema/routing/routing-1.0.xsd">
|
xsi:schemaLocation="http://symfony.com/schema/routing http://symfony.com/schema/routing/routing-1.0.xsd">
|
||||||
|
|
||||||
|
<route id="_profiler_home" pattern="/">
|
||||||
|
<default key="_controller">web_profiler.controller.profiler:homeAction</default>
|
||||||
|
</route>
|
||||||
|
|
||||||
<route id="_profiler_search" pattern="/search">
|
<route id="_profiler_search" pattern="/search">
|
||||||
<default key="_controller">web_profiler.controller.profiler:searchAction</default>
|
<default key="_controller">web_profiler.controller.profiler:searchAction</default>
|
||||||
</route>
|
</route>
|
||||||
@ -52,14 +56,4 @@
|
|||||||
<default key="_controller">web_profiler.controller.exception:cssAction</default>
|
<default key="_controller">web_profiler.controller.exception:cssAction</default>
|
||||||
</route>
|
</route>
|
||||||
|
|
||||||
<route id="_profiler_redirect" pattern="/">
|
|
||||||
<default key="_controller">FrameworkBundle:Redirect:redirect</default>
|
|
||||||
<default key="route">_profiler_search_results</default>
|
|
||||||
<default key="token">empty</default>
|
|
||||||
<default key="ip"></default>
|
|
||||||
<default key="url"></default>
|
|
||||||
<default key="method"></default>
|
|
||||||
<default key="limit">10</default>
|
|
||||||
</route>
|
|
||||||
|
|
||||||
</routes>
|
</routes>
|
||||||
|
Reference in New Issue
Block a user