Skip to content

Commit 3088d69

Browse files
committed
Add escaping of template code
1 parent 43f6bcf commit 3088d69

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

view/base/templates/script/variables.phtml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ if (!is_numeric($mobileWidth) || $mobileWidth < 100) {
1818
?>
1919
<script>
2020
var LOKI_BASE_URL = '<?= $escaper->escapeUrl($block->getBaseUrl()) ?>';
21-
var LOKI_FORM_KEY = '<?= /* @noEscape */ $formKeyValue->get() ?>';
21+
var LOKI_FORM_KEY = '<?= $escaper->escapeHtml($formKeyValue->get()) ?>';
2222
var LOKI_CURRENT_URL = window.location.href.split('?')[0];
2323
var LOKI_IS_MOBILE = ((window.innerWidth > 0) ? window.innerWidth : screen.width) < <?= (int)$mobileWidth ?>; // @todo: What happens if you change browser width on the fly?
2424
</script>

0 commit comments

Comments
 (0)