Skip to content

Commit

Permalink
minor #6166 Fix by_reference deprecated FormType::class (nemo-)
Browse files Browse the repository at this point in the history
This PR was merged into the 2.8 branch.

Discussion
----------

Fix by_reference deprecated FormType::class

| Q             | A
| ------------- | ---
| Doc fix?      | yes
| New docs?     | no
| Applies to    |  2.8, 3.0, 3.1
| Fixed tickets | -

Commits
-------

5d1806e Fix by_reference deprecated FormType::class
  • Loading branch information
xabbuh committed Jan 19, 2016
2 parents f398b03 + 5d1806e commit 8e91949
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion reference/forms/types/options/by_reference.rst.inc
Expand Up @@ -12,13 +12,14 @@ To explain this further, here's a simple example::

use Symfony\Component\Form\Extension\Core\Type\TextType;
use Symfony\Component\Form\Extension\Core\Type\EmailType;
use Symfony\Component\Form\Extension\Core\Type\FormType;
// ...

$builder = $this->createFormBuilder($article);
$builder
->add('title', TextType::class)
->add(
$builder->create('author', 'form', array('by_reference' => ?))
$builder->create('author', FormType::class, array('by_reference' => ?))
->add('name', TextType::class)
->add('email', EmailType::class)
)
Expand Down

0 comments on commit 8e91949

Please sign in to comment.