Skip to content

Commit

Permalink
Fix CS
Browse files Browse the repository at this point in the history
  • Loading branch information
romainneutron committed Nov 10, 2012
1 parent d304649 commit 0b25fac
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions components/console/introduction.rst
Expand Up @@ -304,7 +304,7 @@ convenient for passwords::

When you ask an hidden response, Symfony will use either a binary, change
stty mode or use another trick to hide the response. If none is available,
it will fallback on the classic question unless you pass `false` as the
it will fallback on the classic question unless you pass ``false`` as the
third argument like in the example above. In this case, a RuntimeException
would be thrown.

Expand All @@ -316,7 +316,7 @@ You can easily ask question and validate response with built-in methods::
$dialog = $this->getHelperSet()->get('dialog');

$validator = function ($value) {
if (trim($value) === '') {
if (trim($value) == '') {
throw new \Exception('The value can not be empty');
}
}
Expand All @@ -330,18 +330,18 @@ You can easily ask question and validate response with built-in methods::
);

The validation callback can be any callable PHP function, the fourth argument is
the maximum number of attempts, set it to `false` for unlimited attempts. The
the maximum number of attempts, set it to ``false`` for unlimited attempts. The
fifth argument is the default value.

.. versionadded:: 2.2
The ``askHiddenResponse`` method was added in Symfony 2.2.
The ``askHiddenResponseAndValidate`` method was added in Symfony 2.2.

You can also ask and validate hidden response::

$dialog = $this->getHelperSet()->get('dialog');

$validator = function ($value) {
if (trim($value) === '') {
if (trim($value) == '') {
throw new \Exception('The password can not be empty');
}
}
Expand Down

0 comments on commit 0b25fac

Please sign in to comment.