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 e5c82c5

Browse filesBrowse files
committed
bug #36789 Change priority of KernelEvents::RESPONSE subscriber (marcw)
This PR was squashed before being merged into the 4.4 branch. Discussion ---------- Change priority of KernelEvents::RESPONSE subscriber | Q | A | ------------- | --- | Branch? | 4.4 | Bug fix? | yes | New feature? | no | Deprecations? | no | License | MIT This PR changes the priority of the `KernelEvents::RESPONSE` subscriber of the `ProfilerListener` so that it is the penultimate to be executed (just before `StreamedResponseListener`). The reason is that other listeners that were executed after this one CAN change the response (such as `SessionListener` for example). This creates a headache when debugging, with a discrepancy between what is shown in a curl command, and by the Symfony profiler. Commits ------- 6ed624a Change priority of KernelEvents::RESPONSE subscriber
2 parents 3150104 + 6ed624a commit e5c82c5
Copy full SHA for e5c82c5

File tree

Expand file treeCollapse file tree

1 file changed

+1
-1
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+1
-1
lines changed

‎src/Symfony/Component/HttpKernel/EventListener/ProfilerListener.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/HttpKernel/EventListener/ProfilerListener.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ public function onKernelTerminate(PostResponseEvent $event)
119119
public static function getSubscribedEvents()
120120
{
121121
return [
122-
KernelEvents::RESPONSE => ['onKernelResponse', -100],
122+
KernelEvents::RESPONSE => ['onKernelResponse', -1012],
123123
KernelEvents::EXCEPTION => ['onKernelException', 0],
124124
KernelEvents::TERMINATE => ['onKernelTerminate', -1024],
125125
];

0 commit comments

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