Skip to content

Commit 5726e65

Browse files
committed
remove the ability to pass a tag to FormThemeNode
1 parent 9f4d2b9 commit 5726e65

File tree

4 files changed

+7
-12
lines changed

4 files changed

+7
-12
lines changed

UPGRADE-8.0.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -491,6 +491,7 @@ Translation
491491
TwigBridge
492492
----------
493493

494+
* Remove support for passing a tag to the constructor of `FormThemeNode`
494495
* Remove `text` format from the `debug:twig` command, use the `txt` format instead
495496

496497
TwigBundle

src/Symfony/Bridge/Twig/CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,11 @@
11
CHANGELOG
22
=========
33

4+
8.0
5+
---
6+
7+
* Remove support for passing a tag to the constructor of `FormThemeNode`
8+
49
7.3
510
---
611

src/Symfony/Bridge/Twig/Node/FormThemeNode.php

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -22,18 +22,8 @@
2222
#[YieldReady]
2323
final class FormThemeNode extends Node
2424
{
25-
/**
26-
* @param bool $only
27-
*/
28-
public function __construct(Node $form, Node $resources, int $lineno, $only = false)
25+
public function __construct(Node $form, Node $resources, int $lineno, bool $only = false)
2926
{
30-
if (null === $only || \is_string($only)) {
31-
trigger_deprecation('symfony/twig-bridge', '3.12', 'Passing a tag to %s() is deprecated.', __METHOD__);
32-
$only = \func_num_args() > 4 ? func_get_arg(4) : true;
33-
} elseif (!\is_bool($only)) {
34-
throw new \TypeError(\sprintf('Argument 4 passed to "%s()" must be a boolean, "%s" given.', __METHOD__, get_debug_type($only)));
35-
}
36-
3727
parent::__construct(['form' => $form, 'resources' => $resources], ['only' => $only], $lineno);
3828
}
3929

src/Symfony/Bridge/Twig/composer.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717
],
1818
"require": {
1919
"php": ">=8.4",
20-
"symfony/deprecation-contracts": "^2.5|^3",
2120
"symfony/translation-contracts": "^2.5|^3",
2221
"twig/twig": "^3.21"
2322
},

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy