Skip to content

Commit dba896b

Browse files
committed
Merge branch '6.0' into 6.1
* 6.0: [DependencyInjecion] Mention that service definitions replace previous ones
2 parents 3e417bf + f3a612d commit dba896b

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

service_container.rst

+9
Original file line numberDiff line numberDiff line change
@@ -175,6 +175,9 @@ each time you ask for it.
175175
- '../src/Entity/'
176176
- '../src/Kernel.php'
177177
178+
# order is important in this file because service definitions
179+
# always *replace* previous ones; add your own service configuration below
180+
178181
# ...
179182
180183
.. code-block:: xml
@@ -194,6 +197,9 @@ each time you ask for it.
194197
<!-- this creates a service per class whose id is the fully-qualified class name -->
195198
<prototype namespace="App\" resource="../src/" exclude="../src/{DependencyInjection,Entity,Kernel.php}"/>
196199
200+
<!-- order is important in this file because service definitions
201+
always *replace* previous ones; add your own service configuration below -->
202+
197203
<!-- ... -->
198204
199205
</services>
@@ -216,6 +222,9 @@ each time you ask for it.
216222
// this creates a service per class whose id is the fully-qualified class name
217223
$services->load('App\\', '../src/')
218224
->exclude('../src/{DependencyInjection,Entity,Kernel.php}');
225+
226+
// order is important in this file because service definitions
227+
// always *replace* previous ones; add your own service configuration below
219228
};
220229
221230
.. tip::

0 commit comments

Comments
 (0)