/**
* {@inheritdoc}
*/
- public function buildForm(FormBuilderInterface $builder, array $options) {
+ public function buildForm(FormBuilderInterface $builder, array $options): void {
//Add fields
$builder
->add('name', TextType::class, ['attr' => ['placeholder' => 'Your name'], 'constraints' => [new NotBlank(['message' => 'Please provide your name'])]])
/**
* {@inheritdoc}
*/
- public function configureOptions(OptionsResolver $resolver) {
+ public function configureOptions(OptionsResolver $resolver): void {
//Set defaults
$resolver->setDefaults(['error_bubbling' => true]);
}
/**
* {@inheritdoc}
*/
- public function getName() {
+ public function getName(): string {
return 'contact_form';
}
}