Skip to content

Instantly share code, notes, and snippets.

View skobkin's full-sized avatar
💭
Let's delete this code.

Alexey Skobkin skobkin

💭
Let's delete this code.
View GitHub Profile
@skobkin
skobkin / README.md
Last active August 27, 2024 16:47
ReflectionExtractor somewhat unexpected type detection behavior

Using Symfony Serializer with Symfony\Component\PropertyInfo\Extractor\ReflectionExtractor will cause the type of $url property to be detected incorrectly.

$serializer->deserialize(SomeResponse::class, '{"url": "http://test"}');

We'll get an exception with an error like this: