forward the caught exception

This commit is contained in:
Christian Flothmann 2020-10-20 14:40:03 +02:00
parent 65b41dea0d
commit 143f82ef8e

View File

@ -115,7 +115,7 @@ class PropertyAccessor implements PropertyAccessorInterface
return;
} catch (\TypeError $e) {
self::throwInvalidArgumentException($e->getMessage(), $e->getTrace(), 0, $propertyPath);
self::throwInvalidArgumentException($e->getMessage(), $e->getTrace(), 0, $propertyPath, $e);
// It wasn't thrown in this class so rethrow it
throw $e;
}