@@ -173,6 +173,8 @@ will be autocompleted as the user types::
173173 public function execute(InputInterface $input, OutputInterface $output)
174174 {
175175 // ...
176+ $helper = $this->getHelper('question');
177+
176178 $bundles = array('AcmeDemoBundle', 'AcmeBlogBundle', 'AcmeStoreBundle');
177179 $question = new Question('Please enter the name of a bundle', 'FooBundle');
178180 $question->setAutocompleterValues($bundles);
@@ -192,6 +194,8 @@ convenient for passwords::
192194 public function execute(InputInterface $input, OutputInterface $output)
193195 {
194196 // ...
197+ $helper = $this->getHelper('question');
198+
195199 $question = new Question('What is the database password?');
196200 $question->setHidden(true);
197201 $question->setHiddenFallback(false);
@@ -225,6 +229,8 @@ method::
225229 public function execute(InputInterface $input, OutputInterface $output)
226230 {
227231 // ...
232+ $helper = $this->getHelper('question');
233+
228234 $question = new Question('Please enter the name of the bundle', 'AppBundle');
229235 $question->setNormalizer(function ($value) {
230236 // $value can be null here
@@ -256,6 +262,8 @@ method::
256262 public function execute(InputInterface $input, OutputInterface $output)
257263 {
258264 // ...
265+ $helper = $this->getHelper('question');
266+
259267 $question = new Question('Please enter the name of the bundle', 'AcmeDemoBundle');
260268 $question->setValidator(function ($answer) {
261269 if (!is_string($answer) || 'Bundle' !== substr($answer, -6)) {
0 commit comments