Skip to content

Commit

Permalink
Fix invalid JSON at widget initialization
Browse files Browse the repository at this point in the history
Since `2.6.1` json initializing `magepalGtmDatalayer` is invalid. This breaks scripts execusion, it's IMO critical:
```{
        "*": {
            "magepalGtmDatalayer": {
                "dataLayer": "<?= /* @NoEscape */ $block->getDataLayerName() ?>"
            }
        }
    }```
  • Loading branch information
mborkowski authored Mar 30, 2021
1 parent 302593d commit 2103d1e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion view/frontend/templates/js.phtml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ $containerCode = $block->getEmbeddedCode();
{
"*": {
"magepalGtmDatalayer": {
"dataLayer": "<?= /* @noEscape */ $block->getDataLayerName() ?>",
"dataLayer": "<?= /* @noEscape */ $block->getDataLayerName() ?>"
}
}
}
Expand Down

0 comments on commit 2103d1e

Please sign in to comment.