Movatterモバイル変換


[0]ホーム

URL:


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

Sign up
Appearance settings

Commit01b71a4

Browse files
committed
[Form] Removed trigger_error() for deprecations as of 3.0
1 parent81f8c67 commit01b71a4

File tree

4 files changed

+7
-12
lines changed

4 files changed

+7
-12
lines changed

‎src/Symfony/Bridge/Twig/Node/FormEnctypeNode.php‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,8 @@ public function compile(\Twig_Compiler $compiler)
2424
parent::compile($compiler);
2525

2626
$compiler->raw(";\n");
27-
$compiler->write('trigger_error(\'The helper form_enctype(form) is deprecated since version 2.3 and will be removed in 3.0. Use form_start(form) instead.\', E_USER_DEPRECATED)');
27+
28+
// Uncomment this as soon as the deprecation note should be shown
29+
// $compiler->write('trigger_error(\'The helper form_enctype(form) is deprecated since version 2.3 and will be removed in 3.0. Use form_start(form) instead.\', E_USER_DEPRECATED)');
2830
}
2931
}

‎src/Symfony/Bundle/FrameworkBundle/Templating/Helper/FormHelper.php‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,8 @@ public function end(FormView $view, array $variables = array())
136136
*/
137137
publicfunctionenctype(FormView$view)
138138
{
139-
trigger_error('The form helper $view[\'form\']->enctype() is deprecated since version 2.3 and will be removed in 3.0. Use $view[\'form\']->start() instead.',E_USER_DEPRECATED);
139+
// Uncomment this as soon as the deprecation note should be shown
140+
// trigger_error('The form helper $view[\'form\']->enctype() is deprecated since version 2.3 and will be removed in 3.0. Use $view[\'form\']->start() instead.', E_USER_DEPRECATED);
140141

141142
return$this->renderer->searchAndRenderBlock($view,'enctype');
142143
}

‎src/Symfony/Component/Form/Extension/HttpFoundation/EventListener/BindRequestListener.php‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,8 @@ public function preBind(FormEvent $event)
4343
return;
4444
}
4545

46-
trigger_error('Passing a Request instance to Form::bind() is deprecated since version 2.3 and will be disabled in 3.0. Call Form::process($request) instead.',E_USER_DEPRECATED);
46+
// Uncomment this as soon as the deprecation note should be shown
47+
// trigger_error('Passing a Request instance to Form::bind() is deprecated since version 2.3 and will be disabled in 3.0. Call Form::process($request) instead.', E_USER_DEPRECATED);
4748

4849
$name =$form->getConfig()->getName();
4950
$default =$form->getConfig()->getCompound() ?array() :null;

‎src/Symfony/Component/Form/Tests/FormIntegrationTestCase.php‎

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -32,15 +32,6 @@ protected function setUp()
3232
$this->factory = Forms::createFormFactoryBuilder()
3333
->addExtensions($this->getExtensions())
3434
->getFormFactory();
35-
36-
set_error_handler(array('Symfony\Component\Form\Test\DeprecationErrorHandler','handle'));
37-
}
38-
39-
protectedfunctiontearDown()
40-
{
41-
$this->factory =null;
42-
43-
restore_error_handler();
4435
}
4536

4637
protectedfunctiongetExtensions()

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp