Skip to content

Commit

Permalink
Merge branch '2.8' into 3.4
Browse files Browse the repository at this point in the history
* 2.8:
  Fix "payload" usage
  Update custom_authentication_provider.rst
  Add a note about correct cfg value server_version for MariaDB
  Fixes year in license
  Update property_info.rst
  Fixed a minor RST syntax issue
  fix YAML code block indentation
  • Loading branch information
javiereguiluz committed Apr 16, 2018
2 parents 12dc42c + c09ffff commit 16faf60
Show file tree
Hide file tree
Showing 7 changed files with 21 additions and 15 deletions.
6 changes: 3 additions & 3 deletions components/property_info.rst
Original file line number Diff line number Diff line change
Expand Up @@ -316,9 +316,9 @@ Type::getBuiltInType()
~~~~~~~~~~~~~~~~~~~~~~

The :method:`Type::getBuiltinType() <Symfony\\Component\\PropertyInfo\\Type::getBuiltinType>`
method will return the built-in PHP data type, which can be one of 9 possible
string values: ``array``, ``bool``, ``callable``, ``float``, ``int``, ``null``,
``object``, ``resource`` or ``string``.
method returns the built-in PHP data type, which can be one of these
string values: ``array``, ``bool``, ``callable``, ``float``, ``int``,
``iterable``, ``null``, ``object``, ``resource`` or ``string``.

Constants inside the :class:`Symfony\\Component\\PropertyInfo\\Type`
class, in the form ``Type::BUILTIN_TYPE_*``, are provided for convenience.
Expand Down
4 changes: 2 additions & 2 deletions contributing/code/core_team.rst
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,8 @@ Former Core Members
They are no longer part of the Core Team, but we are very grateful for all their
Symfony contributions:

* **Bernhard Schussek** (`webmozart`_);
* **Abdellatif AitBoudad** (`aitboudad`_).
* **Bernhard Schussek** (`webmozart`_);
* **Abdellatif AitBoudad** (`aitboudad`_).

Core Membership Application
~~~~~~~~~~~~~~~~~~~~~~~~~~~
Expand Down
2 changes: 1 addition & 1 deletion contributing/code/license.rst
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ According to `Wikipedia`_:
The License
-----------

Copyright (c) 2004-2017 Fabien Potencier
Copyright (c) 2004-2018 Fabien Potencier

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
7 changes: 5 additions & 2 deletions reference/configuration/doctrine.rst
Original file line number Diff line number Diff line change
Expand Up @@ -371,8 +371,11 @@ The following block shows all possible configuration keys:
your database server version (use ``postgres -V`` or ``psql -V`` command
to find your PostgreSQL version and ``mysql -V`` to get your MySQL
version).

Always wrap the server version number with quotes to parse it as a string

  If you are running a MariaDB database, you must prefix the ``server_version``
value with ``mariadb-`` (e.g. ``server_version: mariadb-10.2.12``).

  Always wrap the server version number with quotes to parse it as a string
instead of a float number. Otherwise, the floating-point representation
issues can make your version be considered a different number (e.g. ``5.6``
will be rounded as ``5.5999999999999996447286321199499070644378662109375``).
Expand Down
10 changes: 5 additions & 5 deletions security/custom_authentication_provider.rst
Original file line number Diff line number Diff line change
Expand Up @@ -131,17 +131,17 @@ set an authenticated token in the token storage if successful::
{
$request = $event->getRequest();

$wsseRegex = '/UsernameToken Username="([^"]+)", PasswordDigest="([^"]+)", Nonce="([a-zA-Z0-9+\/]+={0,2})", Created="([^"]+)"/';
$wsseRegex = '/UsernameToken Username="(?P<username>[^"]+)", PasswordDigest="(?P<digest>[^"]+)", Nonce="(?P<nonce>[a-zA-Z0-9+\/]+={0,2})", Created="(?P<created>[^"]+)"/';
if (!$request->headers->has('x-wsse') || 1 !== preg_match($wsseRegex, $request->headers->get('x-wsse'), $matches)) {
return;
}

$token = new WsseUserToken();
$token->setUser($matches[1]);
$token->setUser($matches['username']);

$token->digest = $matches[2];
$token->nonce = $matches[3];
$token->created = $matches[4];
$token->digest = $matches['digest'];
$token->nonce = $matches['nonce'];
$token->created = $matches['created'];

try {
$authToken = $this->authenticationManager->authenticate($token);
Expand Down
3 changes: 3 additions & 0 deletions service_container/lazy_services.rst
Original file line number Diff line number Diff line change
Expand Up @@ -51,12 +51,14 @@ You can mark the service as ``lazy`` by manipulating its definition:

.. code-block:: yaml
# app/config/services.yml
services:
AppBundle\Twig\AppExtension:
lazy: true
.. code-block:: xml
<!-- app/config/services.xml -->
<?xml version="1.0" encoding="UTF-8" ?>
<container xmlns="http://symfony.com/schema/dic/services"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
Expand All @@ -70,6 +72,7 @@ You can mark the service as ``lazy`` by manipulating its definition:
.. code-block:: php
// app/config/services.php
use AppBundle\Twig\AppExtension;
$container->register(AppExtension::class)
Expand Down
4 changes: 2 additions & 2 deletions validation/severity.rst
Original file line number Diff line number Diff line change
Expand Up @@ -148,8 +148,8 @@ so that the severity is added as an additional HTML class:
{%- if errors|length > 0 -%}
<ul>
{%- for error in errors -%}
{% if error.cause.constraint.payload.severity is defined %}
{% set severity = error.cause.constraint.payload.severity %}
{% if error.constraint.payload.severity is defined %}
{% set severity = error.constraint.payload.severity %}
{% endif %}
<li{% if severity is defined %} class="{{ severity }}"{% endif %}>{{ error.message }}</li>
{%- endfor -%}
Expand Down

0 comments on commit 16faf60

Please sign in to comment.