Make the exception message more clear.

This commit is contained in:
Tobias Nyholm 2016-07-07 17:57:55 +02:00 committed by Fabien Potencier
parent 41d6758ee5
commit 6344ccd7b1

View File

@ -39,7 +39,7 @@ class PropertyMetadata extends MemberMetadata
public function __construct($class, $name) public function __construct($class, $name)
{ {
if (!property_exists($class, $name)) { if (!property_exists($class, $name)) {
throw new ValidatorException(sprintf('Property %s does not exist in class %s', $name, $class)); throw new ValidatorException(sprintf('Property "%s" does not exist in class "%s"', $name, $class));
} }
parent::__construct($class, $name, $name); parent::__construct($class, $name, $name);