8000 [HttpKernel] collect bundle classes, not paths · symfony/symfony@7824d75 · GitHub
[go: up one dir, main page]

Skip to content

Commit 7824d75

Browse files
[HttpKernel] collect bundle classes, not paths
1 parent 2a91f28 commit 7824d75

File tree

2 files changed

+3
-5
lines changed

2 files changed

+3
-5
lines changed

src/Symfony/Bundle/WebProfilerBundle/Resources/views/Collector/config.html.twig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -210,7 +210,7 @@
210210
<thead>
211211
<tr>
212212
<th class="key">Name</th>
213-
<th>Path</th>
213+
<th>Class</th>
214214
</tr>
215215
</thead>
216216
<tbody>

src/Symfony/Component/HttpKernel/DataCollector/ConfigDataCollector.php

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
use Symfony\Component\HttpFoundation\Response;
1616
use Symfony\Component\HttpKernel\Kernel;
1717
use Symfony\Component\HttpKernel\KernelInterface;
18-
use Symfony\Component\VarDumper\Caster\LinkStub;
18+
use Symfony\Component\VarDumper\Caster\ClassStub;
1919

2020
/**
2121
* @author Fabien Potencier <fabien@symfony.com>
@@ -30,7 +30,6 @@ class ConfigDataCollector extends DataCollector implements LateDataCollectorInte
3030
private $kernel;
3131
private $name;
3232
private $version;
33-
private $hasVarDumper;
3433

3534
public function __construct(string $name = null, string $version = null)
3635
{
@@ -43,7 +42,6 @@ public function __construct(string $name = null, string $version = null)
4342

4443
$this->name = $name;
4544
$this->version = $version;
46-
$this->hasVarDumper = class_exists(LinkStub::class);
4745
}
4846

4947
/**
@@ -82,7 +80,7 @@ public function collect(Request $request, Response $response/*, \Throwable $exce
8280

8381
if (isset($this->kernel)) {
8482
foreach ($this->kernel->getBundles() as $name => $bundle) {
85-
$this->data['bundles'][$name] = $this->hasVarDumper ? new LinkStub($bundle->getPath()) : $bundle->getPath();
83+
$this->data['bundles'][$name] = new ClassStub(\get_class($bundle));
8684
}
8785

8886
$this->data['symfony_state'] = $this->determineSymfonyState();

0 commit comments

Comments
 (0)
0