diff --git a/doc/templates.rst b/doc/templates.rst index 63853561478..3cd8f9b90c7 100644 --- a/doc/templates.rst +++ b/doc/templates.rst @@ -869,7 +869,7 @@ determine how to convert the code to PHP: {# it is converted to the following PHP code: (6 & 2) || (6 & 16) #} -Change the default precedence by explicitely grouping expressions with parentheses: +Change the default precedence by explicitly grouping expressions with parentheses: .. code-block:: twig diff --git a/src/Sandbox/SecurityPolicy.php b/src/Sandbox/SecurityPolicy.php index f7e26962696..988e37216cf 100644 --- a/src/Sandbox/SecurityPolicy.php +++ b/src/Sandbox/SecurityPolicy.php @@ -69,9 +69,9 @@ public function checkSecurity($tags, $filters, $functions): void foreach ($tags as $tag) { if (!\in_array($tag, $this->allowedTags)) { if ('extends' === $tag) { - trigger_deprecation('twig/twig', '3.12', 'The "extends" tag is always allowed in sandboxes, but won\'t be in 4.0, please enable it explicitely in your sandbox policy if needed.'); + trigger_deprecation('twig/twig', '3.12', 'The "extends" tag is always allowed in sandboxes, but won\'t be in 4.0, please enable it explicitly in your sandbox policy if needed.'); } elseif ('use' === $tag) { - trigger_deprecation('twig/twig', '3.12', 'The "use" tag is always allowed in sandboxes, but won\'t be in 4.0, please enable it explicitely in your sandbox policy if needed.'); + trigger_deprecation('twig/twig', '3.12', 'The "use" tag is always allowed in sandboxes, but won\'t be in 4.0, please enable it explicitly in your sandbox policy if needed.'); } else { throw new SecurityNotAllowedTagError(\sprintf('Tag "%s" is not allowed.', $tag), $tag); } diff --git a/tests/Extension/SandboxTest.php b/tests/Extension/SandboxTest.php index 611eec54171..d193e7ef903 100644 --- a/tests/Extension/SandboxTest.php +++ b/tests/Extension/SandboxTest.php @@ -110,7 +110,7 @@ public function getSandboxedForCoreTagsTests() */ public function testSandboxForExtendsAndUseTags(string $tag, string $template) { - $this->expectDeprecation(sprintf('Since twig/twig 3.12: The "%s" tag is always allowed in sandboxes, but won\'t be in 4.0, please enable it explicitely in your sandbox policy if needed.', $tag)); + $this->expectDeprecation(sprintf('Since twig/twig 3.12: The "%s" tag is always allowed in sandboxes, but won\'t be in 4.0, please enable it explicitly in your sandbox policy if needed.', $tag)); $twig = $this->getEnvironment(true, [], self::$templates, []); $twig->createTemplate($template, 'index')->render([]);