Skip to content

Commit

Permalink
CONST instead of VAR
Browse files Browse the repository at this point in the history
  • Loading branch information
Emrah Gunduz committed Jan 31, 2018
1 parent 79ffaaf commit 72e7189
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion iterate.php
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ function iterateDOM ( DOMNode $domNode )
$parentNames[ $currentLevel ] = $name;
$lastNodeName = $name;

$js .= "var {$name} = document.createElement('{$node->nodeName}');\n";
$js .= "const {$name} = document.createElement('{$node->nodeName}');\n";
if ( $node->hasAttributes() ) {
foreach ( $node->attributes as $attr ) {
$attrName = $attr->nodeName;
Expand Down

0 comments on commit 72e7189

Please sign in to comment.