diff --git a/src/Symfony/Component/Validator/ConstraintViolationList.php b/src/Symfony/Component/Validator/ConstraintViolationList.php index 808a69a182..55e5acbf1b 100644 --- a/src/Symfony/Component/Validator/ConstraintViolationList.php +++ b/src/Symfony/Component/Validator/ConstraintViolationList.php @@ -50,7 +50,7 @@ class ConstraintViolationList implements \IteratorAggregate, \Countable, \ArrayA $root = $violation->getRoot(); $class = (string) (is_object($root) ? get_class($root) : $root); $propertyPath = (string) $violation->getPropertyPath(); - if ('' !== $propertyPath && '[' !== $propertyPath{0} && '' !== $class) { + if ('' !== $propertyPath && '[' !== $propertyPath[0] && '' !== $class) { $class .= '.'; } $string .= <<