[HttpKernel] fixed route parameters storage in the Request data collector (closes #8867)

This commit is contained in:
Fabien Potencier 2013-08-30 19:08:44 +02:00
parent 7a0eba4ddc
commit c931eb7a53
1 changed files with 7 additions and 3 deletions

View File

@ -51,10 +51,14 @@ class RequestDataCollector extends DataCollector implements EventSubscriberInter
$attributes = array();
foreach ($request->attributes->all() as $key => $value) {
if ('_route' == $key && is_object($value)) {
$value = $value->getPath();
$attributes['_route'] = $this->varToString($value->getPath());
} elseif ('_route_params' == $key) {
foreach ($value as $key => $v) {
$attributes['_route_params'][$key] = $this->varToString($v);
}
} else {
$attributes[$key] = $this->varToString($value);
}
$attributes[$key] = $this->varToString($value);
}
$content = null;