Skip to content

Commit 36f44c9

Browse files
committed
Update some terminology based on AlexJS reports
1 parent 42740dd commit 36f44c9

File tree

85 files changed

+251
-239
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

85 files changed

+251
-239
lines changed

.alexrc

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
{
2+
"allow": [
3+
"attack",
4+
"attacks",
5+
"bigger",
6+
"color",
7+
"colors",
8+
"failure",
9+
"hook",
10+
"hooks",
11+
"host-hostess",
12+
"invalid",
13+
"remain",
14+
"special"
15+
]
16+
}

bundles.rst

+3-3
Original file line numberDiff line numberDiff line change
@@ -45,9 +45,9 @@ Creating a Bundle
4545
-----------------
4646

4747
This section creates and enables a new bundle to show there are only a few steps required.
48-
The new bundle is called AcmeTestBundle, where the ``Acme`` portion is just a
49-
dummy name that should be replaced by some "vendor" name that represents you or
50-
your organization (e.g. ABCTestBundle for some company named ``ABC``).
48+
The new bundle is called AcmeTestBundle, where the ``Acme`` portion is a dummy
49+
name that should be replaced by some "vendor" name that represents you or your
50+
organization (e.g. ABCTestBundle for some company named ``ABC``).
5151

5252
Start by creating a ``src/Acme/TestBundle/`` directory and adding a new file
5353
called ``AcmeTestBundle.php``::

configuration.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -351,7 +351,7 @@ a new ``locale`` parameter is added to the ``config/services.yaml`` file).
351351
Configuration Environments
352352
--------------------------
353353

354-
You have just one application, but whether you realize it or not, you need it
354+
You have only one application, but whether you realize it or not, you need it
355355
to behave differently at different times:
356356

357357
* While **developing**, you want to log everything and expose nice debugging tools;

configuration/dot-env-changes.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@ important changes:
2020

2121
* B) The ``.env`` file **is** now committed to your repository. It was previously ignored
2222
via the ``.gitignore`` file (the updated recipe does not ignore this file). Because
23-
this file is committed, it should contain non-sensitive, default values. Basically,
24-
the ``.env.dist`` file was moved to ``.env``.
23+
this file is committed, it should contain non-sensitive, default values. The
24+
``.env`` can be seen as the previous ``.env.dist`` file.
2525

2626
* C) A ``.env.local`` file can now be created to *override* values in ``.env`` for
2727
your machine. This file is ignored in the new ``.gitignore``.

configuration/front_controllers_and_kernel.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ The `front controller`_ is a design pattern; it is a section of code that *all*
3030
requests served by an application run through.
3131

3232
In the Symfony Skeleton, this role is taken by the ``index.php`` file in the
33-
``public/`` directory. This is the very first PHP script executed when a
33+
``public/`` directory. This is the very first PHP script that is run when a
3434
request is processed.
3535

3636
The main purpose of the front controller is to create an instance of the

configuration/micro_kernel_trait.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ via Composer:
2020
symfony/http-foundation symfony/routing \
2121
symfony/dependency-injection symfony/framework-bundle
2222
23-
Next, create an ``index.php`` file that defines the kernel class and executes it::
23+
Next, create an ``index.php`` file that defines the kernel class and runs it::
2424

2525
// index.php
2626
use Symfony\Bundle\FrameworkBundle\Kernel\MicroKernelTrait;

configuration/multiple_kernels.rst

+6-7
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ request to generate the response.
1616

1717
This single kernel approach is a convenient default, but Symfony applications
1818
can define any number of kernels. Whereas
19-
:ref:`environments <configuration-environments>` execute the same application
20-
with different configurations, kernels can execute different parts of the same
19+
:ref:`environments <configuration-environments>` run the same application with
20+
different configurations, kernels can run different parts of the same
2121
application.
2222

2323
These are some of the common use cases for creating multiple kernels:
@@ -123,7 +123,7 @@ Finally, define the configuration files that the new ``ApiKernel`` will load.
123123
According to the above code, this config will live in one or multiple files
124124
stored in ``config/api/`` and ``config/api/ENVIRONMENT_NAME/`` directories.
125125

126-
The new configuration files can be created from scratch when you load just a few
126+
The new configuration files can be created from scratch when you load only a few
127127
bundles, because it will be small. Otherwise, duplicate the existing
128128
config files in ``config/packages/`` or better, import them and override the
129129
needed options.
@@ -133,13 +133,12 @@ Executing Commands with a Different Kernel
133133

134134
The ``bin/console`` script used to run Symfony commands always uses the default
135135
``Kernel`` class to build the application and load the commands. If you need
136-
to execute console commands using the new kernel, duplicate the ``bin/console``
136+
to run console commands using the new kernel, duplicate the ``bin/console``
137137
script and rename it (e.g. ``bin/api``).
138138

139139
Then, replace the ``Kernel`` instance by your own kernel instance
140-
(e.g. ``ApiKernel``) and now you can execute commands using the new kernel
141-
(e.g. ``php bin/api cache:clear``) Now you can use execute commands using the
142-
new kernel.
140+
(e.g. ``ApiKernel``). Now you can run commands using the new kernel
141+
(e.g. ``php bin/api cache:clear``).
143142

144143
.. note::
145144

configuration/using_parameters_in_dic.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@ There are special cases such as when you want, for instance, to use the
1010
``%kernel.debug%`` parameter to make the services in your bundle enter
1111
debug mode. For this case there is more work to do in order
1212
to make the system understand the parameter value. By default,
13-
your parameter ``%kernel.debug%`` will be treated as a
14-
simple string. Consider the following example::
13+
your parameter ``%kernel.debug%`` will be treated as a string. Consider the
14+
following example::
1515

1616
// inside Configuration class
1717
$rootNode

console.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ this is already done for you, thanks to :ref:`autoconfiguration <services-autoco
113113
Executing the Command
114114
---------------------
115115

116-
After configuring and registering the command, you can execute it in the terminal:
116+
After configuring and registering the command, you can run it in the terminal:
117117

118118
.. code-block:: terminal
119119

console/calling_commands.rst

+10-10
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
How to Call Other Commands
22
==========================
33

4-
If a command depends on another one being run before it, instead of asking the
5-
user to remember the order of execution, you can call it directly yourself.
6-
This is also useful if you want to create a "meta" command that just runs a
7-
bunch of other commands (for instance, all commands that need to be run when
8-
the project's code has changed on the production servers: clearing the cache,
9-
generating Doctrine2 proxies, dumping web assets, ...).
4+
If a command depends on another one being run before it you can call in the
5+
console command itself. This is useful if a command depends on another command
6+
or if you want to create a "meta" command that runs a bunch of other commands
7+
(for instance, all commands that need to be run when the project's code has
8+
changed on the production servers: clearing the cache, generating Doctrine
9+
proxies, dumping web assets, ...).
1010

1111
Calling a command from another one is straightforward::
1212

@@ -31,13 +31,13 @@ Calling a command from another one is straightforward::
3131
}
3232

3333
First, you :method:`Symfony\\Component\\Console\\Application::find` the
34-
command you want to execute by passing the command name. Then, you need to create
34+
command you want to run by passing the command name. Then, you need to create
3535
a new :class:`Symfony\\Component\\Console\\Input\\ArrayInput` with the arguments
3636
and options you want to pass to the command.
3737

38-
Eventually, calling the ``run()`` method actually executes the command and
39-
returns the returned code from the command (return value from command's
40-
``execute()`` method).
38+
Eventually, calling the ``run()`` method actually runs the command and returns
39+
the returned code from the command (return value from command's ``execute()``
40+
method).
4141

4242
.. tip::
4343

console/command_in_controller.rst

+5-5
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,11 @@ The :doc:`Console component documentation </components/console>` covers how to
88
create a console command. This article covers how to use a console command
99
directly from your controller.
1010

11-
You may have the need to execute some function that is only available in a
12-
console command. Usually, you should refactor the command and move some logic
13-
into a service that can be reused in the controller. However, when the command
14-
is part of a third-party library, you wouldn't want to modify or duplicate
15-
their code. Instead, you can execute the command directly.
11+
You may have the need to call some function that is only available in a console
12+
command. Usually, you should refactor the command and move some logic into a
13+
service that can be reused in the controller. However, when the command is part
14+
of a third-party library, you don't want to modify or duplicate their code.
15+
Instead, you can run the command directly from the controller.
1616

1717
.. caution::
1818

console/commands_as_services.rst

+3-2
Original file line numberDiff line numberDiff line change
@@ -52,8 +52,9 @@ For example, suppose you want to log something from within your command::
5252

5353
If you're using the :ref:`default services.yaml configuration <service-container-services-load-example>`,
5454
the command class will automatically be registered as a service and passed the ``$logger``
55-
argument (thanks to autowiring). In other words, *just* by creating this class, everything
56-
works! You can call the ``app:sunshine`` command and start logging.
55+
argument (thanks to autowiring). In other words, you only need to create this
56+
class and everything works automatically! You can call the ``app:sunshine``
57+
command and start logging.
5758

5859
.. caution::
5960

console/hide_commands.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@ How to Hide Console Commands
44
By default, all console commands are listed when executing the console application
55
script without arguments or when using the ``list`` command.
66

7-
However, sometimes commands are not intended to be executed by end-users; for
7+
However, sometimes commands are not intended to be run by end-users; for
88
example, commands for the legacy parts of the application, commands exclusively
9-
executed through scheduled tasks, etc.
9+
run through scheduled tasks, etc.
1010

1111
In those cases, you can define the command as **hidden** by setting the
1212
``setHidden()`` method to ``true`` in the command configuration::

console/input.rst

+3-3
Original file line numberDiff line numberDiff line change
@@ -184,13 +184,13 @@ flag:
184184
;
185185

186186
Note that to comply with the `docopt standard`_, long options can specify their
187-
values after a white space or an ``=`` sign (e.g. ``--iterations 5`` or
188-
``--iterations=5``), but short options can only use white spaces or no
187+
values after a whitespace or an ``=`` sign (e.g. ``--iterations 5`` or
188+
``--iterations=5``), but short options can only use whitespaces or no
189189
separation at all (e.g. ``-i 5`` or ``-i5``).
190190

191191
.. caution::
192192

193-
While it is possible to separate an option from its value with a white space,
193+
While it is possible to separate an option from its value with a whitespace,
194194
using this form leads to an ambiguity should the option appear before the
195195
command name. For example, ``php bin/console --iterations 5 app:greet Fabien``
196196
is ambiguous; Symfony would interpret ``5`` as the command name. To avoid

console/lockable_trait.rst

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
Prevent Multiple Executions of a Console Command
2-
================================================
1+
Prevent Running the Same Console Command Multiple Times
2+
=======================================================
33

4-
A simple but effective way to prevent multiple executions of the same command in
5-
a single server is to use `locks`_. The :doc:`Lock component </components/lock>`
6-
provides multiple classes to create locks based on the filesystem (:ref:`FlockStore <lock-store-flock>`),
4+
You can use `locks`_ to prevent the same command from running multiple times on
5+
the same server. The :doc:`Lock component </components/lock>` provides multiple
6+
classes to create locks based on the filesystem (:ref:`FlockStore <lock-store-flock>`),
77
shared memory (:ref:`SemaphoreStore <lock-store-semaphore>`) and even databases
88
and Redis servers.
99

controller.rst

+3-3
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ Controller
77
A controller is a PHP function you create that reads information from the
88
``Request`` object and creates and returns a ``Response`` object. The response could
99
be an HTML page, JSON, XML, a file download, a redirect, a 404 error or anything
10-
else. The controller executes whatever arbitrary logic *your application* needs
10+
else. The controller runs whatever arbitrary logic *your application* needs
1111
to render the content of a page.
1212

1313
.. tip::
@@ -16,9 +16,9 @@ to render the content of a page.
1616
:doc:`/page_creation` and then come back!
1717

1818
.. index::
19-
single: Controller; Simple example
19+
single: Controller; Basic example
2020

21-
A Simple Controller
21+
A Basic Controller
2222
-------------------
2323

2424
While a controller can be any PHP callable (function, method on an object,

controller/argument_value_resolver.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ and defining a service for it. The interface defines two methods:
137137

138138
``supports()``
139139
This method is used to check whether the value resolver supports the
140-
given argument. ``resolve()`` will only be executed when this returns ``true``.
140+
given argument. ``resolve()`` will only be called when this returns ``true``.
141141
``resolve()``
142142
This method will resolve the actual value for the argument. Once the value
143143
is resolved, you must `yield`_ the value to the ``ArgumentResolver``.

controller/error_pages.rst

+5-5
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ How to Customize Error Pages
66
============================
77

88
In Symfony applications, all errors are treated as exceptions, no matter if they
9-
are just a 404 Not Found error or a fatal error triggered by throwing some
10-
exception in your code.
9+
are a 404 Not Found error or a fatal error triggered by throwing some exception
10+
in your code.
1111

1212
In the :ref:`development environment <configuration-environments>`,
1313
Symfony catches all the exceptions and displays a special **exception page**
@@ -19,7 +19,7 @@ with lots of debug information to help you discover the root problem:
1919
:class: with-browser
2020

2121
Since these pages contain a lot of sensitive internal information, Symfony won't
22-
display them in the production environment. Instead, it'll show a simple and
22+
display them in the production environment. Instead, it'll show a minimal and
2323
generic **error page**:
2424

2525
.. image:: /_images/controller/error_pages/errors-in-prod-environment.png
@@ -30,7 +30,7 @@ generic **error page**:
3030
Error pages for the production environment can be customized in different ways
3131
depending on your needs:
3232

33-
#. If you just want to change the contents and styles of the error pages to match
33+
#. If you only want to change the contents and styles of the error pages to match
3434
the rest of your application, :ref:`override the default error templates <use-default-error-controller>`;
3535

3636
#. If you want to change the contents of non-HTML error output,
@@ -39,7 +39,7 @@ depending on your needs:
3939
#. If you also want to tweak the logic used by Symfony to generate error pages,
4040
:ref:`override the default error controller <custom-error-controller>`;
4141

42-
#. If you need total control of exception handling to execute your own logic
42+
#. If you need total control of exception handling to run your own logic
4343
:ref:`use the kernel.exception event <use-kernel-exception-event>`.
4444

4545
.. _use-default-error-controller:

controller/forwarding.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -34,5 +34,5 @@ The target controller method might look something like this::
3434
// ... create and return a Response object
3535
}
3636

37-
Just like when creating a controller for a route, the order of the arguments
38-
of the ``fancy()`` method doesn't matter: the matching is done by name.
37+
Like when creating a controller for a route, the order of the arguments of the
38+
``fancy()`` method doesn't matter: the matching is done by name.

deployment.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ While developing locally, you'll usually store these in ``.env`` and ``.env.loca
128128
on your setup: they can be set at the command line, in your Nginx configuration,
129129
or via other methods provided by your hosting service.
130130

131-
2. Or, create a ``.env.local`` file just like your local development (see note below)
131+
2. Or, create a ``.env.local`` file like your local development (see note below)
132132

133133
There is no significant advantage to either of the two options: use whatever is
134134
most natural in your hosting environment.

doctrine/associations.rst

+6-6
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ There are **two** main relationship/association types:
1515
``ManyToOne`` / ``OneToMany``
1616
The most common relationship, mapped in the database with a foreign
1717
key column (e.g. a ``category_id`` column on the ``product`` table). This is
18-
actually just *one* association type, but seen from the two different *sides*
18+
actually only *one* association type, but seen from the two different *sides*
1919
of the relation.
2020

2121
``ManyToMany``
@@ -299,7 +299,7 @@ config.
299299
*exactly* like an array, but has some added flexibility. Just imagine that
300300
it is an ``array`` and you'll be in good shape.
301301

302-
Your database is setup! Now, execute the migrations like normal:
302+
Your database is setup! Now, run the migrations like normal:
303303

304304
.. code-block:: terminal
305305
@@ -374,8 +374,8 @@ Doctrine takes care of the rest when saving.
374374
Fetching Related Objects
375375
------------------------
376376

377-
When you need to fetch associated objects, your workflow looks just like it
378-
did before. First, fetch a ``$product`` object and then access its related
377+
When you need to fetch associated objects, your workflow looks like it did
378+
before. First, fetch a ``$product`` object and then access its related
379379
``Category`` object::
380380

381381
use App\Entity\Product;
@@ -395,7 +395,7 @@ did before. First, fetch a ``$product`` object and then access its related
395395
}
396396

397397
In this example, you first query for a ``Product`` object based on the product's
398-
``id``. This issues a query for *just* the product data and hydrates the
398+
``id``. This issues a query to fetch *only* the product data and hydrates the
399399
``$product``. Later, when you call ``$product->getCategory()->getName()``,
400400
Doctrine silently makes a second query to find the ``Category`` that's related
401401
to this ``Product``. It prepares the ``$category`` object and returns it to
@@ -493,7 +493,7 @@ This will *still* return an array of ``Product`` objects. But now, when you call
493493
``$product->getCategory()`` and use that data, no second query is made.
494494

495495
Now, you can use this method in your controller to query for a ``Product``
496-
object and its related ``Category`` with just one query::
496+
object and its related ``Category`` in one query::
497497

498498
public function show($id)
499499
{

doctrine/events.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ Doctrine Events
77
`Doctrine`_, the set of PHP libraries used by Symfony to work with databases,
88
provides a lightweight event system to update entities during the application
99
execution. These events, called `lifecycle events`_, allow to perform tasks such
10-
as *"update the createdAt property automatically just before persisting entities
10+
as *"update the createdAt property automatically right before persisting entities
1111
of this type"*.
1212

1313
Doctrine triggers events before/after performing the most common entity

doctrine/multiple_entity_managers.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,7 @@ the default entity manager (i.e. ``default``) is returned::
249249
}
250250
}
251251

252-
You can now use Doctrine just as you did before - using the ``default`` entity
252+
You can now use Doctrine like you did before - using the ``default`` entity
253253
manager to persist and fetch entities that it manages and the ``customer``
254254
entity manager to persist and fetch its entities.
255255

0 commit comments

Comments
 (0)