bug #25981 [DI] Fix tracking of source class changes for lazy-proxies (nicolas-grekas)
This PR was merged into the 3.4 branch.
Discussion
----------
[DI] Fix tracking of source class changes for lazy-proxies
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -
Commits
-------
4f18e4b0dc
[DI] Fix tracking of source class changes for lazy-proxies
This commit is contained in:
commit
6cfcfae009
@ -398,6 +398,8 @@ EOTXT;
|
||||
if (!$proxyDumper->isProxyCandidate($definition)) {
|
||||
continue;
|
||||
}
|
||||
// register class' reflector for resource tracking
|
||||
$this->container->getReflectionClass($definition->getClass());
|
||||
$proxyCode = "\n".$proxyDumper->getProxyCode($definition);
|
||||
if ($strip) {
|
||||
$proxyCode = "<?php\n".$proxyCode;
|
||||
|
@ -842,7 +842,7 @@ abstract class Kernel implements KernelInterface, RebootableInterface, Terminabl
|
||||
$dumper = new PhpDumper($container);
|
||||
|
||||
if (class_exists('ProxyManager\Configuration') && class_exists('Symfony\Bridge\ProxyManager\LazyProxy\PhpDumper\ProxyDumper')) {
|
||||
$dumper->setProxyDumper(new ProxyDumper(substr(hash('sha256', $cache->getPath()), 0, 7)));
|
||||
$dumper->setProxyDumper(new ProxyDumper());
|
||||
}
|
||||
|
||||
$content = $dumper->dump(array(
|
||||
|
Reference in New Issue
Block a user