UserEmailType   A
last analyzed

Complexity

Total Complexity 3

Size/Duplication

Total Lines 19
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 1
Metric Value
wmc 3
eloc 6
c 1
b 0
f 1
dl 0
loc 19
rs 10

3 Methods

Rating   Name   Duplication   Size   Complexity  
A configureOptions() 0 4 1
A getBlockPrefix() 0 3 1
A buildForm() 0 4 1
1
<?php
2
3
namespace App\Form;
4
5
use Symfony\Component\Form\AbstractType;
6
use Symfony\Component\Form\FormBuilderInterface;
7
use Symfony\Component\OptionsResolver\OptionsResolver;
8
9
class UserEmailType extends AbstractType
10
{
11
    public function buildForm(FormBuilderInterface $builder, array $options)
12
    {
13
        $builder
14
            ->add('email')
15
        ;
16
    }
17
18
    public function configureOptions(OptionsResolver $resolver): void
19
    {
20
        $resolver->setDefaults([
21
            'csrf_protection' => false,
22
        ]);
23
    }
24
25
    public function getBlockPrefix(): string
26
    {
27
        return '';
28
    }
29
}
30