Skip to content

Commit 7b7f3cc

Browse files
BaseFormElement: Change param type hint
Since `ValidatorChain::addValidators($param)` requires $param of the type `Traversable<int|string, mixed>`, this class should reflect it.
1 parent a7be352 commit 7b7f3cc

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/FormElement/BaseFormElement.php

+3-2
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
use ipl\Stdlib\Messages;
1313
use ipl\Validator\ValidatorChain;
1414
use ReflectionProperty;
15+
use Traversable;
1516

1617
abstract class BaseFormElement extends BaseHtmlElement implements FormElement, ValueCandidates
1718
{
@@ -184,7 +185,7 @@ public function getValidators()
184185
/**
185186
* Set the validators
186187
*
187-
* @param iterable $validators
188+
* @param Traversable<int|string, mixed> $validators
188189
*
189190
* @return $this
190191
*/
@@ -201,7 +202,7 @@ public function setValidators($validators)
201202
/**
202203
* Add validators
203204
*
204-
* @param iterable $validators
205+
* @param Traversable<int|string, mixed> $validators
205206
*
206207
* @return $this
207208
*/

0 commit comments

Comments
 (0)