This repository has been archived on 2023-08-20. You can view files and clone it, but cannot push or open issues or pull requests.
symfony/src/Symfony
Fabien Potencier b9cc0890c4 feature #22317 [Console] Make SymfonyQuestionHelper::ask optional by default (ro0NL)
This PR was merged into the 4.0-dev branch.

Discussion
----------

[Console] Make SymfonyQuestionHelper::ask optional by default

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | yes
| Tests pass?   | yes (nothing in core depends on it)
| Fixed tickets | #... <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!--highly recommended for new features-->

i noticed when writing commands i always keep doing

```php
$io = new SymfonyStyle($input, $output);
$answer = $io->ask('...', null, function ($value) { return $value; });

// instead of just
$answer = $io->ask('...');
```

only to bypass a built-in validation, of which im not sure why it's there. Note the base question helper doesnt make this assumption...

Commits
-------

2da429cd0a [Console] Make SymfonyQuestionHelper::ask optional by default
2017-07-20 19:25:39 +02:00
..
Bridge Remove last legacy codes 2017-07-18 15:35:15 +02:00
Bundle feature #22317 [Console] Make SymfonyQuestionHelper::ask optional by default (ro0NL) 2017-07-20 19:25:39 +02:00
Component feature #22317 [Console] Make SymfonyQuestionHelper::ask optional by default (ro0NL) 2017-07-20 19:25:39 +02:00