Skip to content

Commit 5d1806e

Browse files
committed
Fix by_reference deprecated FormType::class
1 parent f398b03 commit 5d1806e

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

Diff for: reference/forms/types/options/by_reference.rst.inc

+2-1
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,14 @@ To explain this further, here's a simple example::
1212

1313
use Symfony\Component\Form\Extension\Core\Type\TextType;
1414
use Symfony\Component\Form\Extension\Core\Type\EmailType;
15+
use Symfony\Component\Form\Extension\Core\Type\FormType;
1516
// ...
1617

1718
$builder = $this->createFormBuilder($article);
1819
$builder
1920
->add('title', TextType::class)
2021
->add(
21-
$builder->create('author', 'form', array('by_reference' => ?))
22+
$builder->create('author', FormType::class, array('by_reference' => ?))
2223
->add('name', TextType::class)
2324
->add('email', EmailType::class)
2425
)

0 commit comments

Comments
 (0)