-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
UndeclaredExtension (added by addExtension method) does not serialize to JSON format properly #326
Comments
The following change in JsonParser.java solves the problem. Can you verify if the fix is correct?
The result is: |
I applied the patch, and it works perfectly. Awesome! I'll commit this shortly, and make sure you get the credit. :) |
Ps- I always try to make sure that any who contributes patches gets credit in our changelog. If you want anything other than your github handle listed please feel free to let me know. |
My github handle works great :) Thanks James! |
This bug is found in version 1.4.
The following test code in PatientProvider would generate correct XML document, but wrong JSON document. Note the valueReference in JSON format contains not reference with id.
@READ()
public Patient read(@IdParam IdType theId) {
Patient patient = new Patient();
patient.setBirthDate(new Date());
patient.addExtension().setUrl("test").setValue(new Reference(new Condition()));
return patient;
}
XML:
JSON:
The text was updated successfully, but these errors were encountered: