feature #36372 [VarCloner] Cut Logger in dump (lyrixx)

This PR was merged into the 5.1-dev branch.

Discussion
----------

[VarCloner] Cut Logger in dump

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | no
| Deprecations? | no
| Tickets       |
| License       | MIT
| Doc PR        |

I inject the logger in allmost all my services, and when I dump them
I got the logger and all its dependencies (processor, handler).
So I end up with the TokenStorage, the Session, some Web info...

IMHO, it's better to cut it.

Commits
-------

903a57dbd9 [VarCloner] Cut Logger in dump
This commit is contained in:
Grégoire Pineau 2020-04-07 15:26:54 +02:00
commit 2d6327ff9d

View File

@ -76,6 +76,7 @@ abstract class AbstractCloner implements ClonerInterface
'ErrorException' => ['Symfony\Component\VarDumper\Caster\ExceptionCaster', 'castErrorException'],
'Exception' => ['Symfony\Component\VarDumper\Caster\ExceptionCaster', 'castException'],
'Error' => ['Symfony\Component\VarDumper\Caster\ExceptionCaster', 'castError'],
'Symfony\Bridge\Monolog\Logger' => ['Symfony\Component\VarDumper\Caster\StubCaster', 'cutInternals'],
'Symfony\Component\DependencyInjection\ContainerInterface' => ['Symfony\Component\VarDumper\Caster\StubCaster', 'cutInternals'],
'Symfony\Component\EventDispatcher\EventDispatcherInterface' => ['Symfony\Component\VarDumper\Caster\StubCaster', 'cutInternals'],
'Symfony\Component\HttpClient\CurlHttpClient' => ['Symfony\Component\VarDumper\Caster\SymfonyCaster', 'castHttpClient'],