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 8b8cf56

Browse filesBrowse files
committed
minor #17455 Update framework.exceptions XML and PHP configuration examples (MatTheCat)
This PR was merged into the 5.4 branch. Discussion ---------- Update `framework.exceptions` XML and PHP configuration examples symfony/symfony#48259 doc PR Fix #17609 Commits ------- 246b741 Update `framework.exceptions` XML and PHP configuration examples
2 parents 6f3ff7e + 246b741 commit 8b8cf56
Copy full SHA for 8b8cf56

File tree

Expand file treeCollapse file tree

1 file changed

+8
-13
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+8
-13
lines changed

‎reference/configuration/framework.rst

Copy file name to clipboardExpand all lines: reference/configuration/framework.rst
+8-13Lines changed: 8 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -3579,12 +3579,11 @@ exceptions that match the given exception class:
35793579
http://symfony.com/schema/dic/symfony https://symfony.com/schema/dic/symfony/symfony-1.0.xsd">
35803580
35813581
<framework:config>
3582-
<framework:exceptions>
3583-
<exception id="Symfony\Component\HttpKernel\Exception\BadRequestHttpException">
3584-
<framework:log_level>debug</framework:log_level>
3585-
<framework:status_code>422</framework:status_code>
3586-
</exception>
3587-
</framework:exceptions>
3582+
<framework:exception
3583+
class="Symfony\Component\HttpKernel\Exception\BadRequestHttpException"
3584+
log-level="debug"
3585+
status-code="422"
3586+
/>
35883587
<!-- ... -->
35893588
</framework:config>
35903589
</container>
@@ -3596,13 +3595,9 @@ exceptions that match the given exception class:
35963595
use Symfony\Config\FrameworkConfig;
35973596
35983597
return static function (FrameworkConfig $framework) {
3599-
$framework
3600-
->exceptions(BadRequestHttpException::class)
3601-
->log_level('debug');
3602-
3603-
$framework
3604-
->exceptions(BadRequestHttpException::class)
3605-
->status_code(422);
3598+
$framework->exception(BadRequestHttpException::class)
3599+
->logLevel('debug')
3600+
->statusCode(422)
36063601
;
36073602
};
36083603

0 commit comments

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