8000 Fixed syntax errors on 4.4 · symfony/symfony-docs@2a9103c · GitHub
[go: up one dir, main page]

Skip to content

Commit 2a9103c

Browse files
Nyholmjaviereguiluz
authored andcommitted
Fixed syntax errors on 4.4
1 parent 8c38a35 commit 2a9103c

38 files changed

+105
-74
lines changed

components/console/helpers/formatterhelper.rst

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,9 @@ you can write::
7878
$truncatedMessage = $formatter->truncate($message, 7);
7979
$output->writeln($truncatedMessage);
8080

81-
And the output will be::
81+
And the output will be:
82+
83+
.. code-block:: text
8284
8385
This is...
8486
@@ -93,7 +95,9 @@ from the end of the string::
9395

9496
$truncatedMessage = $formatter->truncate($message, -5);
9597

96-
This will result in::
98+
This will result in:
99+
100+
.. code-block:: text
97101
98102
This is a very long message, which should be trun...
99103

components/console/helpers/table.rst

Lines changed: 2 additions & 2 deletions
< 8000 ul aria-label="File view" class="prc-SegmentedControl-SegmentedControl-e7570 mx-2" data-size="small">
  • Original file line numberDiff line numberDiff line change
    @@ -72,8 +72,8 @@ You can add a table separator anywhere in the output by passing an instance of
    7272
    You can optionally display titles at the top and the bottom of the table::
    7373

    7474
    // ...
    75-
    $table->setHeaderTitle('Books')
    76-
    $table->setFooterTitle('Page 1/2')
    75+
    $table->setHeaderTitle('Books');
    76+
    $table->setFooterTitle('Page 1/2');
    7777
    $table->render();
    7878

    7979
    .. code-block:: terminal

    components/dom_crawler.rst

    Lines changed: 3 additions & 1 deletion
    Original file line numberDiff line numberDiff line change
    @@ -555,7 +555,9 @@ You can virtually set and get values on the form::
    555555
    // where "registration" is its own array
    556556
    $values = $form->getPhpValues();
    557557

    558-
    To work with multi-dimensional fields::
    558+
    To work with multi-dimensional fields:
    559+
    560+
    .. code-block:: html
    559561

    560562
    <form>
    561563
    <input name="multi[]"/>

    components/event_dispatcher.rst

    Lines changed: 1 addition & 1 deletion
    Original file line numberDiff line numberDiff line change
    @@ -238,7 +238,7 @@ determine which instance is passed.
    238238
    $containerBuilder->addCompilerPass(new AddEventAliasesPass([
    239239
    \AcmeFooActionEvent::class => 'acme.foo.action',
    240240
    ]));
    241-
    $containerBuilder->addCompilerPass(new RegisterListenersPass(), PassConfig::TYPE_BEFORE_REMOVING)
    241+
    $containerBuilder->addCompilerPass(new RegisterListenersPass(), PassConfig::TYPE_BEFORE_REMOVING);
    242242

    243243
    $containerBuilder->register('event_dispatcher', EventDispatcher::class);
    244244

    components/filesystem.rst

    Lines changed: 1 addition & 1 deletion
    Original file line numberDiff line numberDiff line change
    @@ -252,7 +252,7 @@ absolute paths and returns the relative path from the second path to the first o
    252252
    '/var/lib/symfony/src/Symfony/Component'
    253253
    );
    254254
    // returns 'videos/'
    255-
    $filesystem->makePathRelative('/tmp/videos', '/tmp')
    255+
    $filesystem->makePathRelative('/tmp/videos', '/tmp');
    256256

    257257
    ``mirror``
    258258
    ~~~~~~~~~~

    components/http_foundation.rst

    Lines changed: 1 addition & 1 deletion
    Original file line numberDiff line numberDiff line change
    @@ -547,7 +547,7 @@ represented by a PHP callable instead of a string::
    547547
    header in the response::
    548548

    549549
    // disables FastCGI buffering in nginx only for this response
    550-
    $response->headers->set('X-Accel-Buffering', 'no')
    550+
    $response->headers->set('X-Accel-Buffering', 'no');
    551551

    552552
    .. _component-http-foundation-serving-files:
    553553

    components/intl.rst

    Lines changed: 5 additions & 5 deletions
    Original file line numberDiff line numberDiff line change
    @@ -11,7 +11,7 @@ The Intl Component
    1111
    .. caution::
    1212

    1313
    The replacement layer is limited to the ``en`` locale. If you want to use
    14-
    other locales, you should `install the intl extension`_. There is no conflict
    14+
    other locales, you should `install the intl extension`_. There is no conflict
    1515
    between the two because, even if you use the extension, this package can still
    1616
    be useful to access the ICU data.
    1717

    @@ -231,9 +231,9 @@ Locales
    231231
    ~~~~~~~
    232232

    233233
    A locale is the combination of a language, a region and some parameters that
    234-
    define the interface preferences of the user. For example, "Chinese" is the
    235-
    language and ``zh_Hans_MO`` is the locale for "Chinese" (language) + "Simplified"
    236-
    (script) + "Macau SAR China" (region). The ``Locales`` class provides access to
    234+
    define the interface preferences of the user. For example, "Chinese" is the
    235+
    language and ``zh_Hans_MO`` is the locale for "Chinese" (language) + "Simplified"
    236+
    (script) + "Macau SAR China" (region). The ``Locales`` class provides access to
    237237
    the name of all locales::
    238238

    239239
    use Symfony\Component\Intl\Locales;
    @@ -351,7 +351,7 @@ translate into any locale with the ``getName()`` method shown earlier::
    351351
    The reverse lookup is also possible thanks to the ``getCountryCode()`` method,
    352352
    which returns the code of the country where the given timezone ID belongs to::
    353353

    354-
    $countryCode = Timezones::getCountryCode('America/Vancouver')
    354+
    $countryCode = Timezones::getCountryCode('America/Vancouver');
    355355
    // => $countryCode = 'CA' (CA = Canada)
    356356

    357357
    The `UTC/GMT time offsets`_ of all timezones are provided by ``getRawOffset()``

    components/lock.rst

    Lines changed: 2 additions & 2 deletions
    Original file line numberDiff line numberDiff line change
    @@ -63,7 +63,7 @@ method can be safely called repeatedly, even if the lock is already acquired.
    6363

    6464
    Unlike other implementations, the Lock Component distinguishes lock
    6565
    instances even when they are created for the same resource. It means that for
    66-
    a given scope and resource one lock instance can be acquired multiple times.
    66+
    a given scope and resource one lock instance can be acquired multiple times.
    6767
    If a lock has to be used by several services, they should share the same ``Lock``
    6868
    instance returned by the ``LockFactory::createLock`` method.
    6969

    @@ -223,7 +223,7 @@ Lock will be released automatically as soon as one process finishes::
    223223
    sleep(30);
    224224
    } else {
    225225
    // Child process
    226-
    echo 'The lock will be released now.'
    226+
    echo 'The lock will be released now.';
    227227
    exit(0);
    228228
    }
    229229
    // ...

    components/options_resolver.rst

    Lines changed: 1 addition & 1 deletion
    Original file line numberDiff line numberDiff line change
    @@ -511,7 +511,7 @@ the closure::
    511511

    512512
    $resolver->setDefault('host', function (Options $options, $previousValue) {
    513513
    if ('ssl' === $options['encryption']) {
    514-
    return 'secure.example.org'
    514+
    return 'secure.example.org';
    515515
    }
    516516

    517517
    // Take default value configured in the base class

    components/phpunit_bridge.rst

    Lines changed: 2 additions & 2 deletions
    Original file line numberDiff line numberDiff line change
    @@ -629,7 +629,7 @@ constraint to test the validity of the email domain::
    629629
    {
    630630
    public function testEmail()
    631631
    {
    632-
    $validator = ...
    632+
    $validator = ...;
    633633
    $constraint = new Email(['checkMX' => true]);
    634634

    635635
    $result = $validator->validate('foo@example.com', $constraint);
    @@ -654,7 +654,7 @@ the data you expect to get for the given hosts::
    654654
    {
    655655
    DnsMock::withMockedHosts(['example.com' => [['type' => 'MX']]]);
    656656

    657-
    $validator = ...
    657+
    $validator = ...;
    658658
    $constraint = new Email(['checkMX' => true]);
    659659

    660660
    $result = $validator->validate('foo@example.com', $constraint);

    0 commit comments

    Comments
     (0)
    0