UserLoginType   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 13
Duplicated Lines 0 %

Test Coverage

Coverage 0%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 6
c 1
b 0
f 0
dl 0
loc 13
ccs 0
cts 10
cp 0
rs 10
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A buildForm() 0 6 1
A getBlockPrefix() 0 3 1
1
<?php
2
namespace App\Form\Type;
3
4
use Symfony\Component\Form\AbstractType;
5
use Symfony\Component\Form\Extension\Core\Type\PasswordType;
6
use Symfony\Component\Form\Extension\Core\Type\SubmitType;
7
use Symfony\Component\Form\Extension\Core\Type\TextType;
8
use Symfony\Component\Form\FormBuilderInterface;
9
10
class UserLoginType extends AbstractType
11
{
12
    public function buildForm(FormBuilderInterface $builder, array $options)
13
    {
14
        $builder
15
            ->add('_username', TextType::class, ['required' => true])
16
            ->add('_password', PasswordType::class, ['required' => true])
17
            ->add('submit', SubmitType::class);
18
    }
19
20
    public function getBlockPrefix()
21
    {
22
        return '';
23
    }
24
}