8000 Merge branch '3.4' into 4.0 · weaverryan/symfony-docs@48063ce · GitHub
[go: up one dir, main page]

Skip to content

Commit 48063ce

Browse files
committed
Merge branch '3.4' into 4.0
* 3.4: event constant mistake Updated the default values of some Cache config options Update simple-example.rst to use const for jQuery Update shared-entry.rst to use Bootstrap 4's SCSS Removed an extra blank line Reword and added a note Link to proxy configuration docs from the routing scheme page Fixed typos Fixed security expression testing user Mentioned Debian explicitly
2 parents 872500f + 7ac5f7b commit 48063ce

File tree

12 files changed

+27
-21
lines changed

12 files changed

+27
-21
lines changed

components/cache/adapters/chain_adapter.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ slowest storage engines, :class:`Symfony\\Component\\Cache\\Adapter\\ApcuAdapter
4646
));
4747

4848
When calling this adapter's :method:`Symfony\\Component\\Cache\\ChainAdapter::prune` method,
49-
the call is deligated to all its compatibe cache adapters. It is safe to mix both adapters
49+
the call is delegated to all its compatible cache adapters. It is safe to mix both adapters
5050
that *do* and do *not* implement :class:`Symfony\\Component\\Cache\\PruneableInterface`, as
5151
incompatible adapters are silently ignored::
5252

components/cache/cache_pools.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -160,18 +160,18 @@ Pruning Cache Items
160160
-------------------
161161

162162
Some cache pools do not include an automated mechanism for pruning expired cache items.
163-
For example, the :ref:`FilesystemAdaper <component-cache-filesystem-adapter>` cache
163+
For example, the :ref:`FilesystemAdapter <component-cache-filesystem-adapter>` cache
164164
does not remove expired cache items *until an item is explicitly requested and determined to
165165
be expired*, for example, via a call to ``Psr\\Cache\\CacheItemPoolInterface::getItem``.
166166
Under certain workloads, this can cause stale cache entries to persist well past their
167167
expiration, resulting in a sizable consumption of wasted disk or memory space from excess,
168168
expired cache items.
169169

170-
This shortcomming has been solved through the introduction of
170+
This shortcoming has been solved through the introduction of
171171
:class:`Symfony\\Component\\Cache\\PruneableInterface`, which defines the abstract method
172172
:method:`Symfony\\Component\\Cache\\PruneableInterface::prune`. The
173173
:ref:`ChainAdapter <component-cache-chain-adapter>`,
174-
:ref:`FilesystemAdaper <component-cache-filesystem-adapter>`,
174+
:ref:`FilesystemAdapter <component-cache-filesystem-adapter>`,
175175
:ref:`PdoAdapter <pdo-doctrine-adapter>`, and
176176
:ref:`PhpFilesAdapter <component-cache-files-adapter>` all implement this new interface,
177177
allowing manual removal of stale cache items::
@@ -185,7 +185,7 @@ allowing manual removal of stale cache items::
185185
The :ref:`ChainAdapter <component-cache-chain-adapter>` implementation does not directly
186186
contain any pruning logic itself. Instead, when calling the chain adapter's
187187
:method:`Symfony\\Component\\Cache\\ChainAdapter::prune` method, the call is delegated to all
188-
its compatibe cache adapters (and those that do not implement ``PruneableInterface`` are
188+
its compatible cache adapters (and those that do not implement ``PruneableInterface`` are
189189
silently ignored)::
190190

191191
use Symfony\Component\Cache\Adapter\ApcuAdapter;

components/console/events.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ Listeners receive a
149149
.. tip::
150150

151151
This event is also dispatched when an exception is thrown by the command.
152-
It is then dispatched just after the ``ConsoleEvents::EXCEPTION`` event.
152+
It is then dispatched just after the ``ConsoleEvents::ERROR`` event.
153153
The exit code received in this case is the exception code.
154154

155155
.. _`reserved exit codes`: http://www.tldp.org/LDP/abs/html/exitcodes.html

components/http_foundation/session_configuration.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -166,8 +166,8 @@ the ``php.ini`` directive ``session.gc_maxlifetime``. The meaning in this contex
166166
that any stored session that was saved more than ``gc_maxlifetime`` ago should be
167167
deleted. This allows one to expire records based on idle time.
168168

169-
However, some operating systems do their own session handling and set the
170-
``session.gc_probability`` variable to ``0`` to stop PHP doing garbage
169+
However, some operating systems (e.g. Debian) do their own session handling and set
170+
the ``session.gc_probability`` variable to ``0`` to stop PHP doing garbage
171171
collection. That's why Symfony now overwrites this value to ``1``.
172172

173173
If you wish to use the original value set in your ``php.ini``, add the following

frontend/encore/legacy-apps.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ Using Libraries that Expect jQuery to be Global
1919
Some legacy JavaScript applications use programming practices that don't play
2020
well with the new practices promoted by Webpack. The most common of these
2121
problems is using code (e.g. jQuery plugins) that assume that jQuery is already
22-
available via the the ``$`` or ``jQuery`` global variables. If those variables
22+
available via the ``$`` or ``jQuery`` global variables. If those variables
2323
are not defined, you'll get these errors:
2424

2525
.. code-block:: text

frontend/encore/shared-entry.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ that's included on every page:
2121
2222
// you can also extract CSS - this will create a 'vendor.css' file
2323
// this CSS will *not* be included in page1.css or page2.css anymore
24-
'bootstrap-sass/assets/stylesheets/_bootstrap.scss'
24+
'bootstrap/scss/bootstrap.scss'
2525
])
2626
2727
As soon as you make this change, you need to include two extra JavaScript files

frontend/encore/simple-example.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ Great! Use ``require()`` to import ``jquery`` and ``greet.js``:
163163
// assets/js/app.js
164164
165165
// loads the jquery package from node_modules
166-
var $ = require('jquery');
166+
const $ = require('jquery');
167167
168 F438 168
// import the function from greet.js (the .js extension is optional)
169169
// ./ (or ../) means to look for a local file

reference/configuration/framework.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2080,8 +2080,8 @@ Full Default Configuration
20802080
20812081
# cache configuration
20822082
cache:
2083-
app: cache.app
2084-
system: cache.system
2083+
app: cache.adapter.filesystem
2084+
system: cache.adapter.system
20852085
directory: '%kernel.cache_dir%/pools'
20862086
default_doctrine_provider: ~
20872087
default_psr6_provider: ~

security.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -984,15 +984,15 @@ You can also use expressions inside your templates:
984984
.. code-block:: html+jinja
985985

986986
{% if is_granted(expression(
987-
'"ROLE_ADMIN" in roles or (user and user.isSuperAdmin())'
987+
'"ROLE_ADMIN" in roles or (not is_anonymous() and user.isSuperAdmin())'
988988
)) %}
989989
<a href="...">Delete</a>
990990
{% endif %}
991991

992992
.. code-block:: html+php
993993

994994
<?php if ($view['security']->isGranted(new Expression(
995-
'"ROLE_ADMIN" in roles or (user and user.isSuperAdmin())'
995+
'"ROLE_ADMIN" in roles or (not is_anonymous() and user.isSuperAdmin())'
996996
))): ?>
997997
<a href="...">Delete</a>
998998
<?php endif; ?>

security/expressions.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ accepts an :class:`Symfony\\Component\\ExpressionLanguage\\Expression` object::
1818
public function index()
1919
{
2020
$this->denyAccessUnlessGranted(new Expression(
21-
'"ROLE_ADMIN" in roles or (user and user.isSuperAdmin())'
21+
'"ROLE_ADMIN" in roles or (not is_anonymous() and user.isSuperAdmin())'
2222
));
2323

2424
// ...

0 commit comments

Comments
 (0)
0