Skip to content

Commit 70e2d18

Browse files
committed
Merge branch '2.7' into 2.8
* 2.7: Username and password in basic auth are allowed to contain '.' Remove obsolete PHPDoc from UriSigner [Serializer] ObjectNormalizer: throw if PropertyAccess isn't installed pdo session fix Fixed unsetting from loosely equal keys OrderedHashMap [Debug] Fix same vendor detection in class loader Updated the source text and translation reject remember-me token if user check fails
2 parents a7992dd + 8d93d4b commit 70e2d18

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

Normalizer/ObjectNormalizer.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
use Symfony\Component\PropertyAccess\PropertyAccessorInterface;
1717
use Symfony\Component\Serializer\Exception\CircularReferenceException;
1818
use Symfony\Component\Serializer\Exception\LogicException;
19+
use Symfony\Component\Serializer\Exception\RuntimeException;
1920
use Symfony\Component\Serializer\Mapping\Factory\ClassMetadataFactoryInterface;
2021
use Symfony\Component\Serializer\NameConverter\NameConverterInterface;
2122

@@ -35,6 +36,10 @@ class ObjectNormalizer extends AbstractNormalizer
3536

3637
public function __construct(ClassMetadataFactoryInterface $classMetadataFactory = null, NameConverterInterface $nameConverter = null, PropertyAccessorInterface $propertyAccessor = null)
3738
{
39+
if (!class_exists('Symfony\Component\PropertyAccess\PropertyAccess')) {
40+
throw new RuntimeException('The ObjectNormalizer class requires the "PropertyAccess" component. Install "symfony/property-access" to use it.');
41+
}
42+
3843
parent::__construct($classMetadataFactory, $nameConverter);
3944

4045
$this->propertyAccessor = $propertyAccessor ?: PropertyAccess::createPropertyAccessor();

0 commit comments

Comments
 (0)