Skip to content

Commit dafab61

Browse files
committed
minor #15 Use ::class constant (yceruto)
This PR was merged into the 1.0-dev branch. Discussion ---------- Use ::class constant Commits ------- 9cdb2ee Use ::class constant
2 parents 8aaa0d8 + 9cdb2ee commit dafab61

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/Resources/skeleton/form/Type.php.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
namespace App\Form;
44

5+
use App\Entity\{{ entity_class_name }};
56
use Symfony\Component\Form\AbstractType;
67
use Symfony\Component\Form\FormBuilderInterface;
78
use Symfony\Component\OptionsResolver\OptionsResolver;
@@ -19,7 +20,7 @@ class {{ form_class_name }} extends AbstractType
1920
{
2021
$resolver->setDefaults(array(
2122
// uncomment if you want to bind to a class
22-
//'data_class' => 'App\Entity\{{ entity_class_name }}'
23+
//'data_class' => {{ entity_class_name }}::class,
2324
));
2425
}
2526
}

0 commit comments

Comments
 (0)