Skip to content

Update logger service channel name #8256

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jan 5, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions reference/dic_tags.rst
Original file line number Diff line number Diff line change
Expand Up @@ -662,7 +662,7 @@ channel when injecting the logger in a service.
AppBundle\Log\CustomLogger:
arguments: ['@logger']
tags:
- { name: monolog.logger, channel: acme }
- { name: monolog.logger, channel: app }

.. code-block:: xml

Expand All @@ -675,7 +675,7 @@ channel when injecting the logger in a service.
<services>
<service id="AppBundle\Log\CustomLogger">
<argument type="service" id="logger" />
<tag name="monolog.logger" channel="acme" />
<tag name="monolog.logger" channel="app" />
</service>
</services>
</container>
Expand All @@ -687,7 +687,7 @@ channel when injecting the logger in a service.

$container->register(CustomLogger::class)
->addArgument(new Reference('logger'))
->addTag('monolog.logger', array('channel' => 'acme'));
->addTag('monolog.logger', array('channel' => 'app'));

.. tip::

Expand Down