Skip to content

Commit 31de7c2

Browse files
committed
feature #19040 [HttpFoundation] Add $flush parameter to Response::send() (alexandre-daubois)
This PR was merged into the 6.4 branch. Discussion ---------- [HttpFoundation] Add `$flush` parameter to `Response::send()` Fix #19039 Commits ------- cea81ec [HttpFoundation] Add $flush parameter to Response::send()
2 parents 6b9d889 + cea81ec commit 31de7c2

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

components/http_foundation.rst

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -487,6 +487,20 @@ Sending the response to the client is done by calling the method
487487

488488
$response->send();
489489

490+
The ``send()`` method takes an optional ``flush`` argument. If set to
491+
``false``, functions like ``fastcgi_finish_request()`` or
492+
``litespeed_finish_request()`` are not called. This is useful when debugging
493+
your application to see which exceptions are thrown in listeners of the
494+
:class:`Symfony\\Component\\HttpKernel\\Event\\TerminateEvent`. You can learn
495+
more about it in
496+
:ref:`the dedicated section about Kernel events <http-kernel-creating-listener>`.
497+
498+
.. versionadded:: 6.4
499+
500+
The ``$flush`` parameter of the
501+
:method:`Symfony\\Component\\HttpFoundation\\Response::send` method
502+
was introduced in Symfony 6.4.
503+
490504
Setting Cookies
491505
~~~~~~~~~~~~~~~
492506

0 commit comments

Comments
 (0)