Skip to content

Commit ebf7b74

Browse files
authored
Remove useless condition
1 parent 000f3e1 commit ebf7b74

File tree

1 file changed

+0
-4
lines changed

1 file changed

+0
-4
lines changed

FormBuilder.php

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -69,10 +69,6 @@ public function add($child, string $type = null, array $options = [])
6969
throw new UnexpectedTypeException($child, 'string or Symfony\Component\Form\FormBuilderInterface');
7070
}
7171

72-
if (null !== $type && !\is_string($type)) {
73-
throw new UnexpectedTypeException($type, 'string or null');
74-
}
75-
7672
// Add to "children" to maintain order
7773
$this->children[$child] = null;
7874
$this->unresolvedChildren[$child] = [$type, $options];

0 commit comments

Comments
 (0)