File tree Expand file tree Collapse file tree 2 files changed +6
-1
lines changed
lib/internal/Magento/Framework/Webapi
Test/Unit/Rest/Response/Renderer Expand file tree Collapse file tree 2 files changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -111,7 +111,7 @@ protected function _formatValue($value)
111
111
/** Without the following transformation boolean values are rendered incorrectly */
112
112
$ value = $ value ? 'true ' : 'false ' ;
113
113
}
114
- return $ value ;
114
+ return ( string ) $ value ;
115
115
}
116
116
117
117
/**
Original file line number Diff line number Diff line change @@ -76,6 +76,11 @@ public function providerXmlRender()
76
76
'<?xml version="1.0"?><response><item_7key>value</item_7key></response> ' ,
77
77
'Invalid XML render with numeric symbol in data index. '
78
78
],
79
+ [
80
+ ['key ' => 'test & foo ' ],
81
+ '<?xml version="1.0"?><response><key>test & foo</key></response> ' ,
82
+ 'Invalid XML render with ampersand symbol in data index. '
83
+ ],
79
84
[
80
85
['.key ' => 'value ' ],
81
86
'<?xml version="1.0"?><response><item_key>value</item_key></response> ' ,
You can’t perform that action at this time.
0 commit comments