Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit a560853

Browse filesBrowse files
bug #52683 [Serializer] Fix constructor deserialization path (mtarld)
This PR was merged into the 5.4 branch. Discussion ---------- [Serializer] Fix constructor deserialization path | Q | A | ------------- | --- | Branch? | 5.4 | Bug fix? | yes | New feature? | no | Deprecations? | no | Issues | Fix #44925 | License | MIT This fix doesn't have to be upmerged because it already has been covered by #46680. Commits ------- 272bc28 [Serializer] Fix constructor deserialization path
2 parents 32f22e0 + 272bc28 commit a560853
Copy full SHA for a560853

File tree

1 file changed

+2
-0
lines changed
Filter options

1 file changed

+2
-0
lines changed

‎src/Symfony/Component/Serializer/Normalizer/AbstractNormalizer.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Serializer/Normalizer/AbstractNormalizer.php
+2Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -489,6 +489,8 @@ protected function denormalizeParameter(\ReflectionClass $class, \ReflectionPara
489489
*/
490490
protected function createChildContext(array $parentContext, string $attribute, ?string $format): array
491491
{
492+
$parentContext['deserialization_path'] = ($parentContext['deserialization_path'] ?? false) ? $parentContext['deserialization_path'].'.'.$attribute : $attribute;
493+
492494
if (isset($parentContext[self::ATTRIBUTES][$attribute])) {
493495
$parentContext[self::ATTRIBUTES] = $parentContext[self::ATTRIBUTES][$attribute];
494496
} else {

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.