Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit c418d9d

Browse filesBrowse files
committed
[Form] Removed constructor argument from FormTypeHttpFoundationExtension for forward compatibility with 2.5
1 parent d671406 commit c418d9d
Copy full SHA for c418d9d

File tree

Expand file treeCollapse file tree

3 files changed

+3
-16
lines changed
Filter options
Expand file treeCollapse file tree

3 files changed

+3
-16
lines changed

‎src/Symfony/Bundle/FrameworkBundle/Resources/config/form.xml

Copy file name to clipboardExpand all lines: src/Symfony/Bundle/FrameworkBundle/Resources/config/form.xml
-3Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -151,11 +151,8 @@
151151
</service>
152152

153153
<!-- FormTypeHttpFoundationExtension -->
154-
<service id="form.server_params" class="Symfony\Component\Form\Util\ServerParams" public="false"/>
155-
156154
<service id="form.type_extension.form.http_foundation" class="Symfony\Component\Form\Extension\HttpFoundation\Type\FormTypeHttpFoundationExtension">
157155
<tag name="form.type_extension" alias="form" />
158-
<argument type="service" id="form.server_params"/>
159156
</service>
160157

161158
<!-- FormTypeValidatorExtension -->

‎src/Symfony/Component/Form/Extension/HttpFoundation/HttpFoundationExtension.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Form/Extension/HttpFoundation/HttpFoundationExtension.php
+1-11Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -21,20 +21,10 @@
2121
*/
2222
class HttpFoundationExtension extends AbstractExtension
2323
{
24-
/**
25-
* @var ServerParams
26-
*/
27-
private $serverParams;
28-
29-
public function __construct(ServerParams $serverParams = null)
30-
{
31-
$this->serverParams = $serverParams;
32-
}
33-
3424
protected function loadTypeExtensions()
3525
{
3626
return array(
37-
new Type\FormTypeHttpFoundationExtension($this->serverParams),
27+
new Type\FormTypeHttpFoundationExtension(),
3828
);
3929
}
4030
}

‎src/Symfony/Component/Form/Extension/HttpFoundation/Type/FormTypeHttpFoundationExtension.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Form/Extension/HttpFoundation/Type/FormTypeHttpFoundationExtension.php
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,10 +32,10 @@ class FormTypeHttpFoundationExtension extends AbstractTypeExtension
3232
*/
3333
private $requestHandler;
3434

35-
public function __construct(ServerParams $serverParams = null)
35+
public function __construct()
3636
{
3737
$this->listener = new BindRequestListener();
38-
$this->requestHandler = new HttpFoundationRequestHandler($serverParams);
38+
$this->requestHandler = new HttpFoundationRequestHandler();
3939
}
4040

4141
/**

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.