Skip to content

Commit 5f8e782

Browse files
committed
use improved Yaml syntax for defining method calls
1 parent 44988e0 commit 5f8e782

File tree

1 file changed

+2
-7
lines changed

1 file changed

+2
-7
lines changed

service_container/calls.rst

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -40,9 +40,7 @@ To configure the container to call the ``setLogger`` method, use the ``calls`` k
4040
App\Service\MessageGenerator:
4141
# ...
4242
calls:
43-
- method: setLogger
44-
arguments:
45-
- '@logger'
43+
- setLogger: ['@logger']
4644
4745
.. code-block:: xml
4846
@@ -121,10 +119,7 @@ The configuration to tell the container it should do so would be like:
121119
App\Service\MessageGenerator:
122120
# ...
123121
calls:
124-
- method: withLogger
125-
arguments:
126-
- '@logger'
127-
returns_clone: true
122+
- withLogger: !returns_clone ['@logger']
128123
129124
.. code-block:: xml
130125

0 commit comments

Comments
 (0)