From 11498e427924340468cabab44c3b42d2f8171504 Mon Sep 17 00:00:00 2001 From: Redouane Date: Thu, 6 Oct 2022 20:54:02 +0100 Subject: [PATCH] migrate to symfony 6 fixed return value of symfony 'current' function, because php native 'current' function may return 'false' with empty array --- FormErrorIterator.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/FormErrorIterator.php b/FormErrorIterator.php index ae265cf59..24047fc15 100644 --- a/FormErrorIterator.php +++ b/FormErrorIterator.php @@ -99,7 +99,7 @@ public function getForm(): FormInterface * * @return T An error or an iterator containing nested errors */ - public function current(): FormError|self + public function current(): FormError|self|bool { return current($this->errors); }