File tree Expand file tree Collapse file tree 3 files changed +8
-4
lines changed
Catalog/Model/Attribute/Backend Expand file tree Collapse file tree 3 files changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -47,7 +47,9 @@ private function validateHtml(DataObject $object): void
47
47
$ attribute = $ this ->getAttribute ();
48
48
$ code = $ attribute ->getAttributeCode ();
49
49
if ($ attribute instanceof Attribute && $ attribute ->getIsHtmlAllowedOnFront ()) {
50
- if ($ object ->getData ($ code )
50
+ $ value = $ object ->getData ($ code );
51
+ if ($ value
52
+ && is_string ($ value )
51
53
&& (!($ object instanceof AbstractModel) || $ object ->getData ($ code ) !== $ object ->getOrigData ($ code ))
52
54
) {
53
55
try {
Original file line number Diff line number Diff line change 293
293
<item name =" alt" xsi : type =" string" >alt</item >
294
294
<item name =" title" xsi : type =" string" >title</item >
295
295
<item name =" border" xsi : type =" string" >border</item >
296
+ <item name =" id" xsi : type =" string" >id</item >
296
297
</argument >
297
298
<argument name =" attributesAllowedByTags" xsi : type =" array" >
298
299
<item name =" a" xsi : type =" array" >
Original file line number Diff line number Diff line change 1856
1856
<item name =" th" xsi : type =" string" >th</item >
1857
1857
<item name =" tfoot" xsi : type =" string" >tfoot</item >
1858
1858
<item name =" img" xsi : type =" string" >img</item >
1859
+ <item name =" hr" xsi : type =" string" >hr</item >
1860
+ <item name =" figure" xsi : type =" string" >figure</item >
1859
1861
</argument >
1860
1862
<argument name =" allowedAttributes" xsi : type =" array" >
1861
1863
<item name =" class" xsi : type =" string" >class</item >
1865
1867
<item name =" alt" xsi : type =" string" >alt</item >
1866
1868
<item name =" title" xsi : type =" string" >title</item >
1867
1869
<item name =" border" xsi : type =" string" >border</item >
1870
+ <item name =" id" xsi : type =" string" >id</item >
1868
1871
</argument >
1869
1872
<argument name =" attributesAllowedByTags" xsi : type =" array" >
1870
1873
<item name =" a" xsi : type =" array" >
1875
1878
</item >
1876
1879
</argument >
1877
1880
<argument name =" attributeValidators" xsi : type =" array" >
1878
- <item name =" style" xsi : type =" array" >
1879
- <item name =" style" xsi : type =" object" >Magento\Framework\Validator\HTML\StyleAttributeValidator</item >
1880
- </item >
1881
+ <item name =" style" xsi : type =" object" >Magento\Framework\Validator\HTML\StyleAttributeValidator</item >
1881
1882
</argument >
1882
1883
</arguments >
1883
1884
</virtualType >
You can’t perform that action at this time.
0 commit comments