-
Notifications
You must be signed in to change notification settings - Fork 9.4k
Closed
Labels
Component: WebapiUse with concrete module component label E.g. "Component: Webapi" + "Catalog"Use with concrete module component label E.g. "Component: Webapi" + "Catalog"Fixed in 2.2.xThe issue has been fixed in 2.2 release lineThe issue has been fixed in 2.2 release lineFixed in 2.3.xThe issue has been fixed in 2.3 release lineThe issue has been fixed in 2.3 release lineIssue: Clear DescriptionGate 2 Passed. Manual verification of the issue description passedGate 2 Passed. Manual verification of the issue description passedIssue: ConfirmedGate 3 Passed. Manual verification of the issue completed. Issue is confirmedGate 3 Passed. Manual verification of the issue completed. Issue is confirmedIssue: Format is validGate 1 Passed. Automatic verification of issue format passedGate 1 Passed. Automatic verification of issue format passedIssue: Ready for WorkGate 4. Acknowledged. Issue is added to backlog and ready for developmentGate 4. Acknowledged. Issue is added to backlog and ready for developmentReproduced on 2.2.xThe issue has been reproduced on latest 2.2 releaseThe issue has been reproduced on latest 2.2 releaseReproduced on 2.3.xThe issue has been reproduced on latest 2.3 releaseThe issue has been reproduced on latest 2.3 release
Description
Preconditions
- Vanilla Magento 2.2.6
- PHP Version 7.0.31
Steps to reproduce
- Create a customer via Backend with the last name "Foo & Bar Corp"
- Create an order (via frontend is fine)
- Export the order via XML interfcae
curl -XPOST -H 'Content-Type: application/json' http://hostname/rest/V1/integration/admin/token -d '{ "username": "admin_username", "password": "admin_password" }'
export B=code received above
curl -X GET --header "Accept: application/xml" --header "Authorization: Bearer $B" "http://hostname/rest/english/V1/orders/1"
Expected result
The customer_lastname
tag should contain Foo & Bar Corp
Actual result
The customer_lastname
tag contains Foo &amp Bar Corp
Summary
So I think at some point (2014) there was a bug in PHP (SimpleXML) that contained the issue with the ampersand, so that was a fix so that this won't influence any functionality. Currently, on 7.0+ this fix doesn't make sense and creates an error.
Proposed solution
Magento\Framework\Webapi\Rest\Response\Renderer
class, _formatValue
method. Delete the replacement of the ampersand. This solves the issue.
Metadata
Metadata
Assignees
Labels
Component: WebapiUse with concrete module component label E.g. "Component: Webapi" + "Catalog"Use with concrete module component label E.g. "Component: Webapi" + "Catalog"Fixed in 2.2.xThe issue has been fixed in 2.2 release lineThe issue has been fixed in 2.2 release lineFixed in 2.3.xThe issue has been fixed in 2.3 release lineThe issue has been fixed in 2.3 release lineIssue: Clear DescriptionGate 2 Passed. Manual verification of the issue description passedGate 2 Passed. Manual verification of the issue description passedIssue: ConfirmedGate 3 Passed. Manual verification of the issue completed. Issue is confirmedGate 3 Passed. Manual verification of the issue completed. Issue is confirmedIssue: Format is validGate 1 Passed. Automatic verification of issue format passedGate 1 Passed. Automatic verification of issue format passedIssue: Ready for WorkGate 4. Acknowledged. Issue is added to backlog and ready for developmentGate 4. Acknowledged. Issue is added to backlog and ready for developmentReproduced on 2.2.xThe issue has been reproduced on latest 2.2 releaseThe issue has been reproduced on latest 2.2 releaseReproduced on 2.3.xThe issue has been reproduced on latest 2.3 releaseThe issue has been reproduced on latest 2.3 release