From 3d241a50936e6ec3a419cc1dd06d87bba19653be Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=A9my=20Romey?= Date: Wed, 3 Aug 2016 19:07:23 +0200 Subject: [PATCH] Fixed service name --- service_container/service_decoration.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/service_container/service_decoration.rst b/service_container/service_decoration.rst index c5d96e99587..ca7fc8e7bab 100644 --- a/service_container/service_decoration.rst +++ b/service_container/service_decoration.rst @@ -40,11 +40,11 @@ the original service is lost: .. code-block:: php - $container->register('mailer', 'AppBundle\Mailer'); + $container->register('app.mailer', 'AppBundle\Mailer'); // this replaces the old app.mailer definition with the new one, the // old definition is lost - $container->register('mailer', 'AppBundle\DecoratingMailer'); + $container->register('app.mailer', 'AppBundle\DecoratingMailer'); Most of the time, that's exactly what you want to do. But sometimes, you might want to decorate the old one instead. In this case, the