-
-
Notifications
You must be signed in to change notification settings - Fork 586
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Property Accessor called with default value of property since 3.18.0 #1421
Comments
Hi @annervisser , Thank for the report. Would you be able to check if the pull request fixes your issue? Thanks! |
Yes, that PR should fix the issue 👍 |
as I can see the PR was already merged, is it missing something else here? |
This should be fixed now in version https://github.com/schmittjoh/serializer/releases/tag/3.23.0 . |
I'm still facing the same issue in release 3.23.0 :/ is it working for you on that version @annervisser ? @annervisser do you mind to reopen this issue, I'm facing the same issue in Edit: Sorry, I was just looking for the new fields that as added {
"traditional": "default",
"traditionalWithSetter": "default",
+ "promoted": "default",
+ "promotedWithSetter": "default"
} But I just realised that, the issue is because there is the suffix {
"traditional": "default",
"traditionalWithSetter": "default",
"promoted": "default",
"promotedWithSetter": "default"
} Then, it's working ✅ :) |
We were still facing an issue with But glad to hear it's fixed for you @eerison |
Yep, This issue was "fixed" (But we have a different output.) But I'm also facing others issues |
Properties that have an Accessor setter, are called with the default property value whenever that class is deserialized
This is a BC break since 3.17.1. It happens since 3.18.0, specifically PR #1417
Steps required to reproduce the problem
$serializer->fromArray([], DefaultValuesAndAccessors::class)
Repo with reproduction: https://github.com/annervisser/jms-serializer-accessor-default-value-repro
Expected Result
Actual Result
output in 3.17.1:
output in 3.18.0:
The text was updated successfully, but these errors were encountered: