Fixed string access by curly brace to bracket

This seems to be the version officially favored by PHP:
http://www.php.net/manual/en/language.types.string.php#language.types.string.substr
This commit is contained in:
Bernhard Schussek 2012-01-31 07:39:54 +01:00
parent a103c28b08
commit 1fc615cdcb
1 changed files with 1 additions and 1 deletions

View File

@ -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 .= <<<EOF