File tree 1 file changed +4
-2
lines changed
1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -135,7 +135,7 @@ inject the ``command.default_name`` parameter:
135
135
services :
136
136
app.command.my_command :
137
137
class : AppBundle\Command\MyCommand
138
- arguments : [' %command.default_name%' ]
138
+ arguments : [" %command.default_name%" ]
139
139
tags :
140
140
- { name: console.command }
141
141
@@ -155,6 +155,7 @@ inject the ``command.default_name`` parameter:
155
155
<services >
156
156
<service id =" app.command.my_command"
157
157
class =" AppBundle\Command\MyCommand" >
158
+ <argument >%command.default_name%</argument >
158
159
<tag name =" console.command" />
159
160
</service >
160
161
</services >
@@ -168,8 +169,9 @@ inject the ``command.default_name`` parameter:
168
169
$container
169
170
->register(
170
171
'app.command.my_command',
171
- 'AppBundle\Command\MyCommand'
172
+ 'AppBundle\Command\MyCommand',
172
173
)
174
+ ->setArguments(array('%command.default_name%'))
173
175
->addTag('console.command')
174
176
;
175
177
You can’t perform that action at this time.
0 commit comments