Skip to content

Commit 19978d1

Browse files
Use array keys to support isset()
Co-authored-by: Ihor Sviziev <ihor-sviziev@users.noreply.github.com>
1 parent c56b4e3 commit 19978d1

File tree

1 file changed

+17
-17
lines changed

1 file changed

+17
-17
lines changed

lib/internal/Magento/Framework/View/Helper/SecureHtmlRender/HtmlRenderer.php

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -19,23 +19,23 @@ class HtmlRenderer
1919
*
2020
* @var array
2121
*/
22-
private const VOID_ELEMENTS = [
23-
'area',
24-
'base',
25-
'br',
26-
'col',
27-
'command',
28-
'embed',
29-
'hr',
30-
'img',
31-
'input',
32-
'keygen',
33-
'link',
34-
'meta',
35-
'param',
36-
'source',
37-
'track',
38-
'wbr'
22+
private const VOID_ELEMENTS_MAP = [
23+
'area' => true,
24+
'base' => true,
25+
'br' => true,
26+
'col' => true,
27+
'command' => true,
28+
'embed' => true,
29+
'hr' => true,
30+
'img' => true,
31+
'input' => true,
32+
'keygen' => true,
33+
'link' => true,
34+
'meta' => true,
35+
'param' => true,
36+
'source' => true,
37+
'track' => true,
38+
'wbr' => true,
3939
];
4040

4141
/**

0 commit comments

Comments
 (0)